IO::Compress::Gzip creates empty file
- From: rfernandez@xxxxxxxxx (Richard Fernandez)
- Date: Thu, 31 Jan 2008 13:06:21 -0500
Hi Folks,
I have the following code:
<snip>
use IO::Compress::Gzip qw(gzip $GzipError);
....then...
gzip "$company.$ext.$date" => "$company.$ext.$date.gz",
BinModeIn => 1 or do {
warn "Failed to gzip file: $company.$ext.$date:
$GzipError\n";
next DOTDONE;
};
</snip>
The file "$company.$ext.$date" is created in the immediately preceding
step and definitely contains data, but the resulting compressed file is
empty, and the warn statement is not executed.
I've extracted and wrapped this code to create a little test program
which works fine, that is, the resulting compressed file contains the
data I expect.
Does anyone know what could possibly be going wrong? Same code, 2
different programs. One works the other does not.
I'm baffled.
Any help is appreciated.
richf
.
- Follow-Ups:
- Re: IO::Compress::Gzip creates empty file
- From: Tom Phoenix
- Re: IO::Compress::Gzip creates empty file
- Prev by Date: Re: JVM thread monitoring
- Next by Date: Re: IO::Compress::Gzip creates empty file
- Previous by thread: JVM thread monitoring
- Next by thread: Re: IO::Compress::Gzip creates empty file
- Index(es):