The exception that is thrown is a boost::iostreams::zlib_error. The error code that's found within is -3 which is defined as Z_DATA_ERROR.

Here is another bit: If I remove the zlib compressor/decompressor (leaving only the encrypt/decrypt) and step through it looks like everything is working fine until the last buffer the decryption routine sees -- which it is unable to decrypt back to plain text. Stepping through the encryption routine seems OK to me though (it appears to properly encrypt everything OK). Note again that I can do the reverse: Remove the encrypt/decrypt but keep the compress/decompress and it works fine.




------------------------------

Message: 6
Date: Sat, 10 Aug 2013 10:11:18 -0500
From: Larry Evans <cppljevans@suddenlink.net>
To: boost-users@lists.boost.org
Subject: Re: [Boost-users] Iostreams with two filters throws exception
        (Ken    Appleby)
Message-ID: <ku5l6f$3so$1@ger.gmane.org>
Content-Type: text/plain; charset=ISO-8859-1

Hi Bryan,

Could you please report what happened when you tried Ken's suggestions
about either catching the exception or using a debugger to narrow down
the cause of the problem?

-regards,
Larry