Change 27516 by [EMAIL PROTECTED] on 2006/03/16 15:19:03
Subject: [PATCH] Compress::Raw::Zlib, Compress::Zlib,
IO::Compress::Zlib 2.000_10
From: "Paul Marquess" <[EMAIL PROTECTED]>
Date: Thu, 16 Mar 2006 14:38:52 -0000
Message-ID: <[EMAIL PROTECTED]>
Affected files ...
... //depot/perl/ext/Compress/IO/Base/Changes#2 edit
... //depot/perl/ext/Compress/IO/Base/README#2 edit
... //depot/perl/ext/Compress/IO/Base/lib/IO/Compress/Base.pm#2 edit
... //depot/perl/ext/Compress/IO/Base/lib/IO/Compress/Base/Common.pm#2 edit
... //depot/perl/ext/Compress/IO/Base/lib/IO/Uncompress/AnyUncompress.pm#2 edit
... //depot/perl/ext/Compress/IO/Base/lib/IO/Uncompress/Base.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/Changes#2 edit
... //depot/perl/ext/Compress/IO/Zlib/Makefile.PL#2 edit
... //depot/perl/ext/Compress/IO/Zlib/README#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Deflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Identity.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Deflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip/Constants.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/RawDeflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip/Constants.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zlib/Constants.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Identity.pm#2
edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Inflate.pm#2
edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/AnyInflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Gunzip.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Inflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/RawInflate.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Unzip.pm#2 edit
... //depot/perl/ext/Compress/IO/Zlib/t/010examples.t#2 edit
... //depot/perl/ext/Compress/IO/Zlib/t/050interop-gzip.t#2 edit
... //depot/perl/ext/Compress/Raw/Zlib/Makefile.PL#2 edit
... //depot/perl/ext/Compress/Raw/Zlib/README#2 edit
... //depot/perl/ext/Compress/Raw/Zlib/Zlib.xs#2 edit
... //depot/perl/ext/Compress/Raw/Zlib/lib/Compress/Raw/Zlib.pm#2 edit
... //depot/perl/ext/Compress/Raw/Zlib/t/02zlib.t#2 edit
... //depot/perl/ext/Compress/Zlib/Changes#10 edit
... //depot/perl/ext/Compress/Zlib/Makefile.PL#19 edit
... //depot/perl/ext/Compress/Zlib/README#10 edit
... //depot/perl/ext/Compress/Zlib/examples/gzcat#5 edit
... //depot/perl/ext/Compress/Zlib/examples/gzstream#5 edit
... //depot/perl/ext/Compress/Zlib/lib/Compress/Zlib.pm#2 edit
... //depot/perl/ext/Compress/Zlib/t/14gzopen.t#9 edit
... //depot/perl/t/lib/compress/generic.pl#3 edit
... //depot/perl/t/lib/compress/tied.pl#3 edit
Differences ...
==== //depot/perl/ext/Compress/IO/Base/Changes#2 (text) ====
Index: perl/ext/Compress/IO/Base/Changes
--- perl/ext/Compress/IO/Base/Changes#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/IO/Base/Changes 2006-03-16 07:19:03.000000000 -0800
@@ -1,6 +1,15 @@
CHANGES
-------
+ 2.000_10 13 March 2006
+
+ * AnyUncompress doesn't assume that IO-Compress-Zlib is installed any
+ more.
+
+ 2.000_09 3 March 2006
+
+ * Released to CPAN.
+
2.000_08 2 March 2006
* Split IO::Compress::Base into its own distribution.
==== //depot/perl/ext/Compress/IO/Base/README#2 (text) ====
Index: perl/ext/Compress/IO/Base/README
--- perl/ext/Compress/IO/Base/README#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/IO/Base/README 2006-03-16 07:19:03.000000000 -0800
@@ -1,9 +1,9 @@
IO::Compress::Base
- Version 2.000_08
+ Version 2.000_10
- 27 Feb 2006
+ 13 Mar 2006
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
@@ -23,7 +23,7 @@
-----------
-This module is a base class for all IO::Compress and IO::Uncompress
+This module is the base class for all IO::Compress and IO::Uncompress
modules.
==== //depot/perl/ext/Compress/IO/Base/lib/IO/Compress/Base.pm#2 (text) ====
Index: perl/ext/Compress/IO/Base/lib/IO/Compress/Base.pm
--- perl/ext/Compress/IO/Base/lib/IO/Compress/Base.pm#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Base/lib/IO/Compress/Base.pm 2006-03-16
07:19:03.000000000 -0800
@@ -20,7 +20,7 @@
our (@ISA, $VERSION, $got_encode);
[EMAIL PROTECTED] = qw(Exporter IO::File);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
#Can't locate object method "SWASHNEW" via package "utf8" (perhaps you forgot
to load "utf8"?) at .../ext/Compress-Zlib/Gzip/blib/lib/Compress/Zlib/Common.pm
line 16.
@@ -968,13 +968,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Compress::Base> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -983,7 +979,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Base/lib/IO/Compress/Base/Common.pm#2 (text)
====
Index: perl/ext/Compress/IO/Base/lib/IO/Compress/Base/Common.pm
--- perl/ext/Compress/IO/Base/lib/IO/Compress/Base/Common.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Base/lib/IO/Compress/Base/Common.pm 2006-03-16
07:19:03.000000000 -0800
@@ -11,7 +11,7 @@
require Exporter;
our ($VERSION, @ISA, @EXPORT, %EXPORT_TAGS);
@ISA = qw(Exporter);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
@EXPORT = qw( isaFilehandle isaFilename whatIsInput whatIsOutput
isaFileGlobString cleanFileGlobString oneTarget
==== //depot/perl/ext/Compress/IO/Base/lib/IO/Uncompress/AnyUncompress.pm#2
(text) ====
Index: perl/ext/Compress/IO/Base/lib/IO/Uncompress/AnyUncompress.pm
--- perl/ext/Compress/IO/Base/lib/IO/Uncompress/AnyUncompress.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Base/lib/IO/Uncompress/AnyUncompress.pm
2006-03-16 07:19:03.000000000 -0800
@@ -6,25 +6,27 @@
use IO::Compress::Base::Common qw(createSelfTiedObject);
-#use IO::Uncompress::Base ;
-use IO::Uncompress::Gunzip ;
-use IO::Uncompress::Inflate ;
-use IO::Uncompress::RawInflate ;
-use IO::Uncompress::Unzip ;
+use IO::Uncompress::Base ;
BEGIN
{
+ eval { require IO::Uncompress::Adapter::Inflate; import
IO::Uncompress::Adapter::Inflate };
eval { require IO::Uncompress::Adapter::Bunzip2; import
IO::Uncompress::Adapter::Bunzip2 };
- eval { require IO::Uncompress::Adapter::LZO; import
IO::Uncompress::Adapter::LZO };
- eval { require IO::Uncompress::Bunzip2; import IO::Uncompress::Bunzip2 };
- eval { require IO::Uncompress::UnLzop; import IO::Uncompress::UnLzop };
+ eval { require IO::Uncompress::Adapter::LZO; import
IO::Uncompress::Adapter::LZO };
+
+ eval { require IO::Uncompress::Bunzip2; import IO::Uncompress::Bunzip2 };
+ eval { require IO::Uncompress::UnLzop; import IO::Uncompress::UnLzop };
+ eval { require IO::Uncompress::Gunzip; import IO::Uncompress::Gunzip };
+ eval { require IO::Uncompress::Inflate; import IO::Uncompress::Inflate };
+ eval { require IO::Uncompress::RawInflate; import
IO::Uncompress::RawInflate };
+ eval { require IO::Uncompress::Unzip; import IO::Uncompress::Unzip };
}
require Exporter ;
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $AnyUncompressError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$AnyUncompressError = '';
@ISA = qw( Exporter IO::Uncompress::Base );
@@ -72,21 +74,26 @@
my $class = shift ;
my $got = shift ;
+ my $magic ;
+
# try zlib first
- my ($obj, $errstr, $errno) =
IO::Uncompress::Adapter::Inflate::mkUncompObject();
+ if (defined $IO::Uncompress::RawInflate::VERSION )
+ {
+ my ($obj, $errstr, $errno) =
IO::Uncompress::Adapter::Inflate::mkUncompObject();
- return $self->saveErrorString(undef, $errstr, $errno)
- if ! defined $obj;
+ return $self->saveErrorString(undef, $errstr, $errno)
+ if ! defined $obj;
- *$self->{Uncomp} = $obj;
-
- my $magic = $self->ckMagic( qw( RawInflate Inflate Gunzip Unzip ) );
+ *$self->{Uncomp} = $obj;
+
+ $magic = $self->ckMagic( qw( RawInflate Inflate Gunzip Unzip ) );
- if ($magic) {
- *$self->{Info} = $self->readHeader($magic)
- or return undef ;
+ if ($magic) {
+ *$self->{Info} = $self->readHeader($magic)
+ or return undef ;
- return 1;
+ return 1;
+ }
}
#foreach my $type ( qw( Bunzip2 UnLzop ) ) {
@@ -158,7 +165,7 @@
=head1 NAME
-IO::Uncompress::AnyUncompress - Perl interface to read 1950, 1951 & 1952
files/buffers
+IO::Uncompress::AnyUncompress - Uncompress gzip, zip, bzip2 or lzop file/buffer
=head1 SYNOPSIS
@@ -225,11 +232,32 @@
-
This module provides a Perl interface that allows the reading of
-any files/buffers.
+files/buffers that have been compressed with a variety of compression
+libraries.
+
+The formats supported are:
+
+=over 5
+
+=item RFC 1950
+
+=item RFC 1951
+
+=item gzip (RFC 1952)
+
+=item zip
+
+=item bzip2
+
+=item lzop
+
+=back
+
+The module will auto-detect which, if any, of the supported
+compression formats is being used.
+
-For writing 1950, 1951 & 1952 files/buffers, see the companion module
IO::Compress::RawDeflate.
@@ -881,13 +909,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::AnyUncompress> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -896,7 +920,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Base/lib/IO/Uncompress/Base.pm#2 (text) ====
Index: perl/ext/Compress/IO/Base/lib/IO/Uncompress/Base.pm
--- perl/ext/Compress/IO/Base/lib/IO/Uncompress/Base.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Base/lib/IO/Uncompress/Base.pm 2006-03-16
07:19:03.000000000 -0800
@@ -10,7 +10,7 @@
@ISA = qw(Exporter );
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
use constant G_EOF => 0 ;
use constant G_ERR => -1 ;
@@ -1316,13 +1316,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::Base> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1331,7 +1327,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/Changes#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/Changes
--- perl/ext/Compress/IO/Zlib/Changes#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/IO/Zlib/Changes 2006-03-16 07:19:03.000000000 -0800
@@ -1,6 +1,14 @@
CHANGES
-------
+ 2.000_10 13 March 2006
+
+ * Documentation updates.
+
+ 2.000_09 3 March 2006
+
+ * Released to CPAN.
+
2.000_08 2 March 2006
* Split IO::Compress::Zlib into its own distribution.
==== //depot/perl/ext/Compress/IO/Zlib/Makefile.PL#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/Makefile.PL
--- perl/ext/Compress/IO/Zlib/Makefile.PL#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/Makefile.PL 2006-03-16 07:19:03.000000000
-0800
@@ -23,6 +23,7 @@
? (MAN3PODS => {})
: (PREREQ_PM => { 'Compress::Raw::Zlib' => 0,
'IO::Compress::Base' => 0,
+ 'IO::Uncompress::Base' => 0,
$] >= 5.005 && $] < 5.006
? ('File::BSDGlob' => 0)
: () }
==== //depot/perl/ext/Compress/IO/Zlib/README#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/README
--- perl/ext/Compress/IO/Zlib/README#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/IO/Zlib/README 2006-03-16 07:19:03.000000000 -0800
@@ -1,9 +1,9 @@
IO::Compress::Zlib
- Version 2.000_08
+ Version 2.000_10
- 27 Feb 2006
+ 13 Mar 2006
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
@@ -23,7 +23,7 @@
-----------
-This module provides a Perl interface to allow reading an writing of RFC
+This module provides a Perl interface to allow reading and writing of RFC
1950, 1951, 1952 (i.e. gzip) and zip files/buffers.
@@ -79,7 +79,7 @@
-The t/17isize Test Suite
+The t/020isize Test Suite
------------------------
This test suite checks that IO::Compress::Zlib can cope with gzip files
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Deflate.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Deflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Deflate.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Deflate.pm
2006-03-16 07:19:03.000000000 -0800
@@ -9,7 +9,7 @@
use Compress::Raw::Zlib qw(Z_OK Z_FINISH MAX_WBITS) ;
our ($VERSION);
-$VERSION = '2.000_05';
+$VERSION = '2.000_10';
sub mkCompObject
{
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Identity.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Identity.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Identity.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Adapter/Identity.pm
2006-03-16 07:19:03.000000000 -0800
@@ -8,7 +8,7 @@
use Compress::Raw::Zlib () ;
our ($VERSION);
-$VERSION = '2.000_05';
+$VERSION = '2.000_10';
sub mkCompObject
{
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Deflate.pm#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Deflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Deflate.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Deflate.pm 2006-03-16
07:19:03.000000000 -0800
@@ -15,7 +15,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $DeflateError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$DeflateError = '';
@ISA = qw(Exporter IO::Compress::RawDeflate);
@@ -167,7 +167,9 @@
=head1 NAME
-IO::Compress::Deflate - Perl interface to write RFC 1950 files/buffers
+
+IO::Compress::Deflate - Write RFC 1950 files/buffers
+
=head1 SYNOPSIS
@@ -573,7 +575,7 @@
-=item -Merge =E<gt> 0|1
+=item Merge =E<gt> 0|1
This option is used to compress input data and append it to an existing
compressed data stream in C<$output>. The end result is a single compressed
@@ -988,13 +990,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Compress::Deflate> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1003,7 +1001,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip.pm#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip.pm#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip.pm 2006-03-16
07:19:03.000000000 -0800
@@ -26,7 +26,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $GzipError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$GzipError = '' ;
@ISA = qw(Exporter IO::Compress::RawDeflate);
@@ -429,7 +429,9 @@
=head1 NAME
-IO::Compress::Gzip - Perl interface to write RFC 1952 files/buffers
+
+IO::Compress::Gzip - Write RFC 1952 files/buffers
+
=head1 SYNOPSIS
@@ -591,16 +593,8 @@
If the C<$input> parameter is any other type, C<undef> will be returned.
-
In addition, if C<$input> is a simple filename, the default values for
-a number of the gzip header fields created by this function will
-be sourced from that file --
-
-the NAME gzip header field will be populated with
-the filename itself, and the MTIME header field will be set to the
-modification time of the file.
-The intention here is to mirror part of the behaviour of the gzip
-executable.
+the C<Name> and C<Time> options will be sourced from that file.
If you do not want to use these defaults they can be overridden by
explicitly setting the C<Name> and C<Time> options or by setting the
@@ -854,7 +848,7 @@
-=item -Merge =E<gt> 0|1
+=item Merge =E<gt> 0|1
This option is used to compress input data and append it to an existing
compressed data stream in C<$output>. The end result is a single compressed
@@ -1465,13 +1459,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Compress::Gzip> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1480,7 +1470,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip/Constants.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip/Constants.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip/Constants.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Gzip/Constants.pm 2006-03-16
07:19:03.000000000 -0800
@@ -9,7 +9,7 @@
our ($VERSION, @ISA, @EXPORT, %GZIP_OS_Names);
our ($GZIP_FNAME_INVALID_CHAR_RE, $GZIP_FCOMMENT_INVALID_CHAR_RE);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
@ISA = qw(Exporter);
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/RawDeflate.pm#2 (text)
====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/RawDeflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/RawDeflate.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/RawDeflate.pm 2006-03-16
07:19:03.000000000 -0800
@@ -16,7 +16,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %DEFLATE_CONSTANTS, %EXPORT_TAGS,
$RawDeflateError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$RawDeflateError = '';
@ISA = qw(Exporter IO::Compress::Base);
@@ -248,7 +248,9 @@
=head1 NAME
-IO::Compress::RawDeflate - Perl interface to write RFC 1951 files/buffers
+
+IO::Compress::RawDeflate - Write RFC 1951 files/buffers
+
=head1 SYNOPSIS
@@ -657,7 +659,7 @@
-=item -Merge =E<gt> 0|1
+=item Merge =E<gt> 0|1
This option is used to compress input data and append it to an existing
compressed data stream in C<$output>. The end result is a single compressed
@@ -1072,13 +1074,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Compress::RawDeflate> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1087,7 +1085,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip.pm#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip.pm#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip.pm 2006-03-16
07:19:03.000000000 -0800
@@ -13,7 +13,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $ZipError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$ZipError = '';
@ISA = qw(Exporter IO::Compress::RawDeflate);
@@ -299,7 +299,9 @@
=head1 NAME
-IO::Compress::Zip - Perl interface to write zip files/buffers
+
+IO::Compress::Zip - Write zip files/buffers
+
=head1 SYNOPSIS
@@ -376,8 +378,9 @@
-Note that this module is not intended to be a replacement for the module
+Note that IO::Compress::Zip is not intended to be a replacement for the module
C<Archive::Zip>.
+
The primary aim of this module is not as an archiver, but to provide
streaming write access to zip file files and buffers.
@@ -463,16 +466,8 @@
If the C<$input> parameter is any other type, C<undef> will be returned.
-
In addition, if C<$input> is a simple filename, the default values for
-a number of the zip header fields created by this function will
-be sourced from that file --
-
-the NAME gzip header field will be populated with
-the filename itself, and the MTIME header field will be set to the
-modification time of the file.
-The intention here is to mirror part of the behaviour of the
-zip executable.
+the C<Name> and C<Time> options will be sourced from that file.
If you do not want to use these defaults they can be overridden by
explicitly setting the C<Name> and C<Time> options or by setting the
@@ -1108,13 +1103,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Compress::Zip> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1123,7 +1114,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip/Constants.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip/Constants.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip/Constants.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zip/Constants.pm 2006-03-16
07:19:03.000000000 -0800
@@ -7,7 +7,7 @@
our ($VERSION, @ISA, @EXPORT, %GZIP_OS_Names);
-$VERSION = '1.00';
+$VERSION = '2.000_10';
@ISA = qw(Exporter);
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zlib/Constants.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zlib/Constants.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zlib/Constants.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Compress/Zlib/Constants.pm 2006-03-16
07:19:03.000000000 -0800
@@ -9,7 +9,7 @@
our ($VERSION, @ISA, @EXPORT);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
@ISA = qw(Exporter);
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Identity.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Identity.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Identity.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Identity.pm
2006-03-16 07:19:03.000000000 -0800
@@ -8,7 +8,7 @@
our ($VERSION);
-$VERSION = '2.000_05';
+$VERSION = '2.000_10';
use Compress::Raw::Zlib ();
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Inflate.pm#2
(text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Inflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Inflate.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Adapter/Inflate.pm
2006-03-16 07:19:03.000000000 -0800
@@ -8,7 +8,7 @@
use Compress::Raw::Zlib qw(Z_OK Z_DATA_ERROR Z_STREAM_END Z_FINISH MAX_WBITS);
our ($VERSION);
-$VERSION = '2.000_05';
+$VERSION = '2.000_10';
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/AnyInflate.pm#2 (text)
====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/AnyInflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/AnyInflate.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/AnyInflate.pm 2006-03-16
07:19:03.000000000 -0800
@@ -21,7 +21,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $AnyInflateError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$AnyInflateError = '';
@ISA = qw( Exporter IO::Uncompress::Base );
@@ -123,7 +123,7 @@
=head1 NAME
-IO::Uncompress::AnyInflate - Perl interface to read RFC 1950, 1951 & 1952
files/buffers
+IO::Uncompress::AnyInflate - Uncompress zlib-based (zip, gzip) file/buffer
=head1 SYNOPSIS
@@ -192,15 +192,32 @@
-
This module provides a Perl interface that allows the reading of
-files/buffers that conform to RFC's 1950, 1951 and 1952.
+files/buffers that have been compressed in a number of formats that use the
+zlib compression library.
+
+The formats supported are
+
+=over 5
+
+=item RFC 1950
+
+=item RFC 1951
+
+=item gzip (RFC 1952)
+
+=item zip
-The module will auto-detect which, if any, of the three supported
+=back
+
+The module will auto-detect which, if any, of the supported
compression formats is being used.
+
+
+
=head1 Functional Interface
A top-level function, C<anyinflate>, is provided to carry out
@@ -940,13 +957,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::AnyInflate> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -955,7 +968,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Gunzip.pm#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Gunzip.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Gunzip.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Gunzip.pm 2006-03-16
07:19:03.000000000 -0800
@@ -27,7 +27,7 @@
$GunzipError = '';
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
sub new
{
@@ -296,7 +296,9 @@
=head1 NAME
-IO::Uncompress::Gunzip - Perl interface to read RFC 1952 files/buffers
+
+IO::Uncompress::Gunzip - Read RFC 1952 files/buffers
+
=head1 SYNOPSIS
@@ -373,6 +375,9 @@
+
+
+
=head1 Functional Interface
A top-level function, C<gunzip>, is provided to carry out
@@ -1112,13 +1117,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::Gunzip> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1127,7 +1128,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Inflate.pm#2 (text)
====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Inflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Inflate.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Inflate.pm 2006-03-16
07:19:03.000000000 -0800
@@ -13,7 +13,7 @@
require Exporter ;
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $InflateError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$InflateError = '';
@ISA = qw( Exporter IO::Uncompress::RawInflate );
@@ -178,7 +178,9 @@
=head1 NAME
-IO::Uncompress::Inflate - Perl interface to read RFC 1950 files/buffers
+
+IO::Uncompress::Inflate - Read RFC 1950 files/buffers
+
=head1 SYNOPSIS
@@ -255,6 +257,9 @@
+
+
+
=head1 Functional Interface
A top-level function, C<inflate>, is provided to carry out
@@ -938,13 +943,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::Inflate> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -953,7 +954,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/RawInflate.pm#2 (text)
====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/RawInflate.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/RawInflate.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/RawInflate.pm 2006-03-16
07:19:03.000000000 -0800
@@ -17,7 +17,7 @@
require Exporter ;
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, %DEFLATE_CONSTANTS,
$RawInflateError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$RawInflateError = '';
@ISA = qw( Exporter IO::Uncompress::Base );
@@ -331,7 +331,9 @@
=head1 NAME
-IO::Uncompress::RawInflate - Perl interface to read RFC 1951 files/buffers
+
+IO::Uncompress::RawInflate - Read RFC 1951 files/buffers
+
=head1 SYNOPSIS
@@ -408,6 +410,9 @@
+
+
+
=head1 Functional Interface
A top-level function, C<rawinflate>, is provided to carry out
@@ -1059,13 +1064,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::RawInflate> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1074,7 +1075,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Unzip.pm#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Unzip.pm
--- perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Unzip.pm#1~27387~
2006-03-06 02:06:53.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/lib/IO/Uncompress/Unzip.pm 2006-03-16
07:19:03.000000000 -0800
@@ -16,7 +16,7 @@
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, $UnzipError);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$UnzipError = '';
@ISA = qw(Exporter IO::Uncompress::RawInflate);
@@ -527,7 +527,9 @@
=head1 NAME
-IO::Uncompress::Unzip - Perl interface to read zip files/buffers
+
+IO::Uncompress::Unzip - Read zip files/buffers
+
=head1 SYNOPSIS
@@ -604,6 +606,9 @@
+
+
+
=head1 Functional Interface
A top-level function, C<unzip>, is provided to carry out
@@ -1273,13 +1278,9 @@
-
-
-
=head1 AUTHOR
-The I<IO::Uncompress::Unzip> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1288,7 +1289,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/IO/Zlib/t/010examples.t#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/t/010examples.t
--- perl/ext/Compress/IO/Zlib/t/010examples.t#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/t/010examples.t 2006-03-16 07:19:03.000000000
-0800
@@ -30,8 +30,8 @@
my $Inc = join " ", map qq["-I$_"] => @INC;
-#$Inc = '"-MExtUtils::testlib"'
-# if ! $ENV{PERL_CORE} && eval " require ExtUtils::testlib; " ;
+$Inc = '"-MExtUtils::testlib"'
+ if ! $ENV{PERL_CORE} && eval " require ExtUtils::testlib; " ;
my $Perl = ($ENV{'FULLPERL'} or $^X or 'perl') ;
$Perl = qq["$Perl"] if $^O eq 'MSWin32' ;
==== //depot/perl/ext/Compress/IO/Zlib/t/050interop-gzip.t#2 (text) ====
Index: perl/ext/Compress/IO/Zlib/t/050interop-gzip.t
--- perl/ext/Compress/IO/Zlib/t/050interop-gzip.t#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/IO/Zlib/t/050interop-gzip.t 2006-03-16
07:19:03.000000000 -0800
@@ -18,7 +18,7 @@
# Check external gzip is available
my $name = 'gzip';
- for my $dir (split ":", $ENV{PATH})
+ for my $dir (reverse split ":", $ENV{PATH})
{
$GZIP = "$dir/$name"
if -x "$dir/$name" ;
@@ -46,14 +46,18 @@
{
my $file = shift ;
+ my $lex = new LexFile my $outfile;
+
my $comp = "$GZIP -dc" ;
- open F, "$comp $file |";
- local $/;
- $_[0] = <F>;
- close F;
+ #diag "$comp $file >$outfile" ;
+
+ system("$comp $file >$outfile") == 0
+ or die "'$comp' failed: $?";
+
+ $_[0] = readFile($outfile);
- return $? ;
+ return 1 ;
}
sub getGzipInfo
@@ -67,14 +71,16 @@
my $content = shift ;
my $options = shift || '';
+ my $lex = new LexFile my $infile;
+ writeFile($infile, $content);
+
unlink $file ;
- my $gzip = "$GZIP -c $options >$file" ;
+ my $gzip = "$GZIP -c $options $infile >$file" ;
- open F, "| $gzip" ;
- print F $content ;
- close F ;
+ system($gzip) == 0
+ or die "'$gzip' failed: $?";
- return $? ;
+ return 1 ;
}
@@ -87,15 +93,15 @@
my $content = "hello world\n" ;
my $got;
- is writeWithGzip($file, $content), 0, "writeWithGzip ok";
+ is writeWithGzip($file, $content), 1, "writeWithGzip ok";
gunzip $file => \$got ;
- is $got, $content;
+ is $got, $content, "got content";
gzip \$content => $file1;
$got = '';
- is readWithGzip($file1, $got), 0, "readWithGzip returns 0";
+ is readWithGzip($file1, $got), 1, "readWithGzip ok";
is $got, $content, "got content";
}
==== //depot/perl/ext/Compress/Raw/Zlib/Makefile.PL#2 (text) ====
Index: perl/ext/Compress/Raw/Zlib/Makefile.PL
--- perl/ext/Compress/Raw/Zlib/Makefile.PL#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Raw/Zlib/Makefile.PL 2006-03-16 07:19:03.000000000
-0800
@@ -329,8 +329,7 @@
-my @GZIP_OS_Names ;
-my %OSnames ;
+use vars qw ( @GZIP_OS_Names %OSnames) ;
BEGIN
{
==== //depot/perl/ext/Compress/Raw/Zlib/README#2 (text) ====
Index: perl/ext/Compress/Raw/Zlib/README
--- perl/ext/Compress/Raw/Zlib/README#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/Raw/Zlib/README 2006-03-16 07:19:03.000000000 -0800
@@ -1,9 +1,9 @@
Compress::Raw::Zlib
- Version 2.000_08
+ Version 2.000_10
- 27 Feb 2006
+ 13 Mar 2006
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
@@ -79,7 +79,6 @@
-
Controlling the version of zlib used by Compress::Raw::Zlib
----------------------------------------------------------
==== //depot/perl/ext/Compress/Raw/Zlib/Zlib.xs#2 (text) ====
Index: perl/ext/Compress/Raw/Zlib/Zlib.xs
--- perl/ext/Compress/Raw/Zlib/Zlib.xs#1~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/Raw/Zlib/Zlib.xs 2006-03-16 07:19:03.000000000 -0800
@@ -1862,7 +1862,8 @@
#ifndef MAGIC_APPEND
croak("resetLastBlockByte needs zlib 1.2.1 or better");
#else
- *byte = *byte ^ (1 << ((8 - s->window_lastbit) & 7));
+ if (byte != NULL)
+ *byte = *byte ^ (1 << ((8 - s->window_lastbit) & 7));
#endif
==== //depot/perl/ext/Compress/Raw/Zlib/lib/Compress/Raw/Zlib.pm#2 (text) ====
Index: perl/ext/Compress/Raw/Zlib/lib/Compress/Raw/Zlib.pm
--- perl/ext/Compress/Raw/Zlib/lib/Compress/Raw/Zlib.pm#1~27384~
2006-03-05 18:06:04.000000000 -0800
+++ perl/ext/Compress/Raw/Zlib/lib/Compress/Raw/Zlib.pm 2006-03-16
07:19:03.000000000 -0800
@@ -13,7 +13,7 @@
use bytes ;
our ($VERSION, $XS_VERSION, @ISA, @EXPORT, $AUTOLOAD);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$XS_VERSION = $VERSION;
$VERSION = eval $VERSION;
@@ -1177,13 +1177,9 @@
-
-
-
=head1 AUTHOR
-The I<Compress::Raw::Zlib> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1192,7 +1188,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 2005-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/Raw/Zlib/t/02zlib.t#2 (text) ====
Index: perl/ext/Compress/Raw/Zlib/t/02zlib.t
--- perl/ext/Compress/Raw/Zlib/t/02zlib.t#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Raw/Zlib/t/02zlib.t 2006-03-16 07:19:03.000000000
-0800
@@ -24,13 +24,13 @@
my $count = 0 ;
if ($] < 5.005) {
- $count = 188 ;
+ $count = 189 ;
}
elsif ($] >= 5.006) {
- $count = 242 ;
+ $count = 243 ;
}
else {
- $count = 200 ;
+ $count = 201 ;
}
plan tests => $count + $extra;
@@ -720,6 +720,13 @@
}
+{
+ # regression - check that resetLastBlockByte can cope with a NULL
+ # pointer.
+ Compress::Raw::Zlib::InflateScan->new->resetLastBlockByte(undef);
+ ok 1, "resetLastBlockByte(undef) is ok" ;
+}
+
exit if $] < 5.006 ;
title 'Looping Append test with substr output - substr the end of the string';
==== //depot/perl/ext/Compress/Zlib/Changes#10 (text) ====
Index: perl/ext/Compress/Zlib/Changes
--- perl/ext/Compress/Zlib/Changes#9~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/Zlib/Changes 2006-03-16 07:19:03.000000000 -0800
@@ -1,11 +1,18 @@
CHANGES
-------
- 2.000_08 2 March 2006
+ 2.000_10 13 March 2006
+
+ * Changed gzread so that its behaviour matches C::Z::gzread 1.x if it
+ is called after eof. In this case it will write an empty string
+ into the output parameter. This change is solely for backward
+ compatability reasons.
- * Moved the IO::* modules out into their own distributions.
+ 2.000_09 3 March 2006
- 2.000_08 9 January 2006
+ * Posted to CPAN
+
+ 2.000_08 2 March 2006
* Breakout zlib specific code into separate modules.
==== //depot/perl/ext/Compress/Zlib/Makefile.PL#19 (xtext) ====
Index: perl/ext/Compress/Zlib/Makefile.PL
--- perl/ext/Compress/Zlib/Makefile.PL#18~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Zlib/Makefile.PL 2006-03-16 07:19:03.000000000 -0800
@@ -21,10 +21,14 @@
(
$ENV{SKIP_FOR_CORE}
? (MAN3PODS => {})
- : (PREREQ_PM => { 'Compress::Raw::Zlib' => 0,
- 'IO::Compress::Base' => 0,
- 'IO::Compress::Zlib' => 0,
- 'Scalar::Util' => 0,
+ : (PREREQ_PM => { 'Compress::Raw::Zlib' => 0,
+ 'IO::Compress::Base' => 0,
+ 'IO::Compress::Base::Common' => 0,
+ 'IO::Uncompress::Base' => 0,
+ 'IO::Compress::Gzip' => 0,
+ 'IO::Compress::Gzip::Constants' => 0,
+ 'IO::Uncompress::Gunzip' => 0,
+ 'Scalar::Util' => 0,
}
)
),
==== //depot/perl/ext/Compress/Zlib/README#10 (text) ====
Index: perl/ext/Compress/Zlib/README
--- perl/ext/Compress/Zlib/README#9~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/ext/Compress/Zlib/README 2006-03-16 07:19:03.000000000 -0800
@@ -1,9 +1,9 @@
Compress::Zlib
- Version 2.000_08
+ Version 2.000_10
- 27 Feb 2006
+ 13 Mar 2006
Copyright (c) 1995-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/Zlib/examples/gzcat#5 (xtext) ====
Index: perl/ext/Compress/Zlib/examples/gzcat
--- perl/ext/Compress/Zlib/examples/gzcat#4~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Zlib/examples/gzcat 2006-03-16 07:19:03.000000000
-0800
@@ -15,11 +15,8 @@
foreach my $filename (@ARGV) {
my $buffer ;
- my $file = $filename ;
- $file = \*STDIN if $file eq '-' ;
-
- my $gz = gzopen($file, "rb")
- or die "Cannot open $file: $gzerrno\n" ;
+ my $gz = gzopen($filename, "rb")
+ or die "Cannot open $filename: $gzerrno\n" ;
print $buffer while $gz->gzread($buffer) > 0 ;
==== //depot/perl/ext/Compress/Zlib/examples/gzstream#5 (xtext) ====
Index: perl/ext/Compress/Zlib/examples/gzstream
--- perl/ext/Compress/Zlib/examples/gzstream#4~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Zlib/examples/gzstream 2006-03-16 07:19:03.000000000
-0800
@@ -7,7 +7,8 @@
binmode STDOUT; # gzopen only sets it on the fd
-my $gz = gzopen(\*STDOUT, "wb")
+#my $gz = gzopen(\*STDOUT, "wb")
+my $gz = gzopen('-', "wb")
or die "Cannot open stdout: $gzerrno\n" ;
while (<>) {
==== //depot/perl/ext/Compress/Zlib/lib/Compress/Zlib.pm#2 (text) ====
Index: perl/ext/Compress/Zlib/lib/Compress/Zlib.pm
--- perl/ext/Compress/Zlib/lib/Compress/Zlib.pm#1~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Zlib/lib/Compress/Zlib.pm 2006-03-16 07:19:03.000000000
-0800
@@ -18,7 +18,7 @@
use bytes ;
our ($VERSION, $XS_VERSION, @ISA, @EXPORT, $AUTOLOAD);
-$VERSION = '2.000_08';
+$VERSION = '2.000_10';
$XS_VERSION = $VERSION;
$VERSION = eval $VERSION;
@@ -158,11 +158,14 @@
return _set_gzerr(Z_STREAM_ERROR())
if $self->[1] ne 'inflate';
- return 0 if $self->gzeof();
+ if ($self->gzeof()) {
+ # Zap the output buffer to match ver 1 behaviour.
+ $_[0] = "" ;
+ return 0 ;
+ }
my $gz = $self->[0] ;
my $status = $gz->read($_[0], defined $_[1] ? $_[1] : 4096) ;
- $_[0] = "" if ! defined $_[0] ;
_save_gzerr($gz, 1);
return $status ;
}
@@ -1436,13 +1439,9 @@
-
-
-
=head1 AUTHOR
-The I<Compress::Zlib> module was written by Paul Marquess,
-F<[EMAIL PROTECTED]>.
+This module was written by Paul Marquess, F<[EMAIL PROTECTED]>.
@@ -1451,7 +1450,6 @@
See the Changes file.
=head1 COPYRIGHT AND LICENSE
-
Copyright (c) 1995-2006 Paul Marquess. All rights reserved.
==== //depot/perl/ext/Compress/Zlib/t/14gzopen.t#9 (text) ====
Index: perl/ext/Compress/Zlib/t/14gzopen.t
--- perl/ext/Compress/Zlib/t/14gzopen.t#8~27384~ 2006-03-05
18:06:04.000000000 -0800
+++ perl/ext/Compress/Zlib/t/14gzopen.t 2006-03-16 07:19:03.000000000 -0800
@@ -20,7 +20,7 @@
$extra = 1
if eval { require Test::NoWarnings ; import Test::NoWarnings; 1 };
- plan tests => 208 + $extra ;
+ plan tests => 210 + $extra ;
use_ok('Compress::Zlib', 2) ;
use_ok('IO::Compress::Gzip::Constants') ;
@@ -70,9 +70,17 @@
is $fil->gztell(), $len;
ok $fil->gzeof() ;
+
+# gzread after eof bahavior
+
+my $xyz = "123" ;
+is $fil->gzread($xyz), 0, "gzread returns 0 on eof" ;
+is $xyz, "", "gzread on eof zaps the output buffer [Match 1,x behavior]" ;
+
ok ! $fil->gzclose ;
ok $fil->gzeof() ;
+
1 while unlink $name ;
ok $hello eq $uncomp ;
==== //depot/perl/t/lib/compress/generic.pl#3 (text) ====
Index: perl/t/lib/compress/generic.pl
--- perl/t/lib/compress/generic.pl#2~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/t/lib/compress/generic.pl 2006-03-16 07:19:03.000000000 -0800
@@ -18,7 +18,7 @@
$extra = 1
if $st ;
- plan(tests => 597 + $extra) ;
+ plan(tests => 601 + $extra) ;
}
sub myGZreadFile
@@ -1260,6 +1260,8 @@
is $u->read($buff, 1), 0;
ok $u->eof() ;
+ # getc returns undef on eof
+ is $u->getc(), undef;
$u->close();
}
==== //depot/perl/t/lib/compress/tied.pl#3 (text) ====
Index: perl/t/lib/compress/tied.pl
--- perl/t/lib/compress/tied.pl#2~27384~ 2006-03-05 18:06:04.000000000
-0800
+++ perl/t/lib/compress/tied.pl 2006-03-16 07:19:03.000000000 -0800
@@ -23,16 +23,14 @@
$BadPerl = ($] >= 5.006 and $] <= 5.008) ;
if ($BadPerl) {
- $tests = 242 ;
+ $tests = 241 ;
}
else {
- $tests = 250 ;
+ $tests = 249 ;
}
plan tests => $tests + $extra ;
- use_ok('Compress::Raw::Zlib') ;
-
}
End of Patch.