Re: deflate parts of a file
- From: "Paul Marquess" <Paul.Marquess@xxxxxxxxxxxxxx>
- Date: Thu, 29 Jun 2006 17:39:15 +0100
"sid" <sridhara@xxxxxxxxx> wrote in message
news:1151596999.818114.126060@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I need to compress parts of a file, say some sections of an xml file
while leaving others as ASCII on the ouput stream. I took the deflate
example from cpan
Which deflate example are you referring to?
and started gathering all lines of a section in a
string and then doing one deflate, ouput, flush and output the
compressed section. But this doesn't seem to be working. I am seeing
"use of uninitialized values" warnings and the final output file
doesn't look right.
I would see some compressed data then a whole bunch
of xml without any compressed data in between and so forth.
Can you post some code please?
The
compress method has a horrible performance. It actually made the file
much bigger.
Hence I only want to use the deflate method. It works fine
on the whole file.
Compression isn't worth the effort on small strings. Ending up with
something bigger is one of the main reasons for not doing it.
But I want to use it on sections of a file. Are
there examples that someone can point me to?
Paul
.
- Follow-Ups:
- Re: deflate parts of a file
- From: sid
- Re: deflate parts of a file
- References:
- deflate parts of a file
- From: sid
- deflate parts of a file
- Prev by Date: Re: prematurely closed filehandle
- Next by Date: Re: Is this a Hash and how can I test a value?
- Previous by thread: deflate parts of a file
- Next by thread: Re: deflate parts of a file
- Index(es):
Relevant Pages
|
|