zlib

"Zlib::GzipFile::CRCError crc error" when install gem packages.

[root@blanee local_cache]# gem install dm-core-0.9.11.gem ERROR: While executing gem ... (Zlib::GzipFile::CRCError) invalid compressed data -- crc error [root@blanee local_cache]# gem install ParseTree-3.0.5.gem ERROR: While executing gem ... (Zlib::GzipFile::CRCError) invalid compressed data -- crc error I have a lot gem p...

Trying to compile a linux-based app on Mac OS X

I'm just trying to compile the linux-based FCEUX (NES emulator) on my mac, OS X 10.5 Leopard. I got all the dependencies (SDL, GTK+ 2) going and everything but of all things this is now my problem: Undefined symbols: "_compress", referenced from: SaveSnapshot() in video.o "_gzclose", referenced from: FCEU_fopen(char const*, char const...

uzing libgz to inflate a gz input

Hi all, I'm currently trying to use the zlib to inflate a source of gzipped data. It seems that the inflate API in zlib cannot inflate a gzipped data ( The example http://www.zlib.net/zpipe.c fails to read a gzipped file: "zpipe: invalid or incomplete deflate data" ). I noticed that there is a gzopen function in this API, but , as far a...

Using ZLib unit to compress files vs using ZipForge

There are many questions on zipping in Delphi, anyway this is not a duplicate. I am using ZipForge for zip/unzip capability in my application. Currently I use 2 features of ZipForge: 1) zip and unzip (!) 2) password protect the archives Now I am removing the password from all the archives so I need only to zip and unzip files. I zip...

Implementing zLib compression in Flex and Java

Hi I am sending some JSON data from my Flex application to the Java side for business processing. Now on top of that, I have added some code to compress(zLib) the data at Flex side and then pass it through Request and uncompress the same at java side. But at the java layer, the uncompressed data is still not in readable/usable format. ...

zlib: Decompressed File Size?

Hi all. I'm using zlib to decompress a file. I want to verify that there is enough disk space to unzip the file. Do the zip format and zlib provide facilities to determine the decompressed size of its contents? ...

How to compress a string in .net c# and decompress it in flash as3?

Hi, I have to load a large xml in flash and I'm trying to send it compressed. To do that I tried to zlib compress the string and send it base64 encoded. In flash I turn the string into a byte array and use its uncompress() method. So far I tried: ZLIB.NET byte[] bytData = System.Text.Encoding.UTF8.GetBytes(str); MemoryStream ms = new ...

zlib.error: Error -3 while decompressing: incorrect header check

Hi, I have a gzip file and I am trying to read it via python as below: import zlib do = zlib.decompressobj(16+zlib.MAX_WBITS) fh = open('abc.gz', 'rb') cdata = fh.read() fh.close() data = do.decompress(cdata) it throws : zlib.error: Error -3 while decompressing: incorrect header check How can I overcome it. ...

Compression problems, zlib?

Hi. I've been googling for long time already, and I still dont know how to use zlib. Could someone just give exact instructions what I have to do to use it? (MS Visual C++ 2010 on Win7 32). Please not the DLL version. Thanks in advance! EDIT: In case someone finds this with google, check the comments! ...

zlib directly for uncompressing a zip folder for iphone

hi, Is it possible to use the bare minimum zlib available on iPhone to uncompress a zip of a folder. I don't want to go for a open source library, please enlighten me the difficulty or possibility of implementing one piece of code which can uncompress a zip file. ...

boost::iostreams::zlib::default_noheader seems to be ignored.

Hi stackoverflow, I'm having trouble getting boost::iostreams's zlib filter to ignore gzip headers ... It seems that setting zlib_param's default_noheader to true and then calling zlib_decompressor() produces the 'data_error' error (incorrect header check). This tells me zlib is still expecting to find headers. Has anyone gotten boost::...

Trying to compile program that uses zlib. Link unresolved error

While trying to compile program, that uses zlib, i got following errors: Error 1 error LNK2019: unresolved external symbol _compress referenced in function "void __cdecl save_image_in_pakfile(class std::basic_ofstream > &,struct _IplImage *)" (?save_image_in_pakfile@@YAXAAV?$basic_ofstream@DU?$char_traits@D@std@@@std@@PAU...

Why am I getting an ferror on my source file using zlib deflate?

EDIT // open output file for writing if ( ( outfilefd = fopen( file_name, "w+t" ) ) == NULL ) { fprintf(stderr, "Unable to create file\n"); exit(1); } Write to the file, then need to zip it. Opening a .z file and then calling def() FILE *zipFile; if ( ( zipFile = fopen( "C:\\LOGS\\test.txt.z", "w+t" ) ...

Analize programatically (python) Symbian v9 E32Image file

I'm trying to analyze programatically (python) a Symbian v9 Logical Device Driver (LDD zlib deflated). I'm able to read E32ImageHeader, but I can't decompress de code section. I always get "zlib.error: Error -3 while decompressing data: invalid block type" import zlib import struct full = "" f = open("c:\\file.ldd","rb") part...

uncompress zlib network packet from hex

Hi, I am reversing some kind of protocol and it looks like it is using zlib compression, the current packet is : 170300002009254CBCE1DC7A5578D1588577EF63AE8DDCA721FFCA453775BCA7375CB65EE31703000090AA883A355CB9A7450EA7BA8D485C655EB5FCB71E22F274E9FF03F326296E7F2D5960AB7CFB2986C4985D6B7D33BE2C7348142D738B522C3B89AA3723A5CADB9C3DF124B3AB4...

need help with zlib!

I wanted to compress my pages so I put ob_start('ob_gzhandler'); at the beginning of my php header file. however as I was playing around I noticed it will give me a blank page if I start a session while the ob_gzhandler was not being used! so I did the below and it worked: how ever I'm not sure if this will always use the compression a...

How to read a char[] object into a tango.io.compress.ZlibStream?

I have a D program with Tango and I'm trying to uncompress a gzipped string. unfortunately I don't have A stream to it, but the compressed data is stored in a char[]. how can I uncompress it using tangos tango.io.compress.ZlibStream? I need another char[] with the uncompressed data. I've been trying this for hours now. I'm not very fami...

sqlite3.ProgrammingError: You must not use 8-bit bytestrings unless you use a text_factory that can interpret 8-bit bytestrings

Using SQLite3 in Python, I am trying to store a compressed version of a snippet of UTF-8 HTML code. Code looks like this: ... c = connection.cursor() c.execute('create table blah (cid integer primary key,html blob)') ... c.execute('insert or ignore into blah values (?, ?)',(cid, zlib.compress(html))) At which point at get the error: ...

PAK archives and zlib (zlib.dylib)

Hi All, I'm currently writing an iPhone app where I need to uncompress several files from .pak archive. I'm assuming libz.dylib will probably have the ability to do this but I'm having a hard time find any code on the subject. Anyone got any example code or can point me in the right direction? Any help at all would be much appreciated...

Zlib compresion technique in asp.net

I am new to .net. I created one website.I want to implement Zlib compression technique for compressing data in each every page, so that i can access open my website quickly.But i don't know where I have to write code for that and how to implement it. Can yo send me the sample application code or zip file. ...