#!/usr/bin/perl use strict ; use warnings ; use Compress::Zlib ; #die "Usage: gzcat file...\n" # unless @ARGV ; my $filename ; @ARGV = '-' unless @ARGV ; foreach my $filename (@ARGV) { my $buffer ; my $gz = gzopen($filename, "rb") or die "Cannot open $filename: $gzerrno\n" ; print $buffer while $gz->gzread($buffer) > 0 ; die "Error reading from $filename: $gzerrno" . ($gzerrno+0) . "\n" if $gzerrno != Z_STREAM_END ; $gz->gzclose() ; }
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
filtdef | File | 437 B | 0644 |
|
filtinf | File | 470 B | 0644 |
|
gzcat | File | 495 B | 0644 |
|
gzgrep | File | 463 B | 0644 |
|
gzstream | File | 314 B | 0644 |
|