On Wed 03 Mar 19:56 2010 Anand Patel wrote:
Not sure if I can suggest anything with given information.  Are you implementing your own filter and using that with bzip2 filter?  How about, providing snippet of your read() operation.
-Anand

On Tue, Mar 2, 2010 at 3:38 PM, eial@cs.bgu.ac.il <eial@cs.bgu.ac.il> wrote:

hello.
I've seem to found a strange behavior within boost::input_filter, I'm writing data to a file using bzip2 compressor, in this issue all goes well, now when I read the data (I post process the data after the de/compression) because some of the chars are negative, then cases where there are two sequential -1 causes the filter to end processing even if the file isn't at eof.
what can be done to prevent it? should this even happen?

here are the test results: http://www.4shared.com/file/233035989/8bde1629/testresults.html

in an essence, I'm taking a data file, passing it into the a base64 encoder and then into a file (that works well) but when I try do the opposite, the problem occurs when I'm trying to convert the base64 file into bzip2, the filter can be found at http://gitorious.org/open-source-soccer-manager/ossm/blobs/master/src/Utilities/Base64Decoder.cpp and http://gitorious.org/open-source-soccer-manager/ossm/blobs/master/src/Utilities/Base64Decoder.hpp