From 1b7caf3368675eb6825e0dca77782a141dfa0392 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Wed, 23 Sep 2009 23:19:38 +0000 Subject: Wow, ok, file was broken on changing position in the stream, it wouldn't reset the end of stream flag. Now it does reset it, and assumes that you've placed the position not at the end, if you have, it will detect it again immediately upon read. BZip2 now provides a method of getting the number of bytes written out, i.e. the compressed size of the output, I have to figure out the input side next... --- src/bzip2.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/bzip2.h') diff --git a/src/bzip2.h b/src/bzip2.h index fd0ba5c..7ca61b4 100644 --- a/src/bzip2.h +++ b/src/bzip2.h @@ -32,6 +32,8 @@ namespace Bu virtual bool isOpen(); + size_t getCompressedSize(); + private: void bzError( int code ); bz_stream bzState; @@ -39,6 +41,7 @@ namespace Bu int nCompression; char *pBuf; uint32_t nBufSize; + size_t sTotalOut; }; } -- cgit v1.2.3