Boost logo

Boost Users :

Subject: Re: [Boost-users] boost::input_filter and negative char
From: eial_at_[hidden]
Date: 2010-03-03 16:50:17


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_at_[hidden][1] <eial_at_[hidden][2]> 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[3]
>>
>>
>
>
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
References:
  1 : eial_at_[hidden]
  2 : eial_at_[hidden]
  3 : http://www.4shared.com/file/233035989/8bde1629/testresults.html



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net