diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2003-07-04 12:59:45 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-07-04 12:59:45 +0000 |
commit | f05fc781a61040f6c41c46560387019732fb8c28 (patch) | |
tree | 4cace445161173a924d7d089ca51c08fc3cb7d82 /ext/Digest | |
parent | 469ddaa3ee4713398fbdc0aaf0e87f5bb0030b0e (diff) | |
download | perl-f05fc781a61040f6c41c46560387019732fb8c28.tar.gz |
Upgrade to Digest::MD5 2.24, with few extra tweaks:
(1) make the PATCHLEVEL logic as it is with List::Util
(more portable to older Perls)
(2) regen the MD5 checksums with ...
(3) ... the Mac OS Classic checksums generated via MacRoman
(just a guess)
(4) Keep the core Makefile.PL.
p4raw-id: //depot/perl@19986
Diffstat (limited to 'ext/Digest')
-rw-r--r-- | ext/Digest/MD5/Changes | 10 | ||||
-rw-r--r-- | ext/Digest/MD5/MD5.pm | 2 | ||||
-rw-r--r-- | ext/Digest/MD5/MD5.xs | 15 | ||||
-rw-r--r-- | ext/Digest/MD5/t/files.t | 24 |
4 files changed, 36 insertions, 15 deletions
diff --git a/ext/Digest/MD5/Changes b/ext/Digest/MD5/Changes index b81bc5267a..a2d69536bf 100644 --- a/ext/Digest/MD5/Changes +++ b/ext/Digest/MD5/Changes @@ -1,3 +1,13 @@ +2003-03-09 Gisle Aas <gisle@ActiveState.com> + + Release 2.24 + + Don't let the $^W test get confused by lexical warnings. + + Sync up with bleadperl; safer patchlevel include. + + + 2003-01-18 Gisle Aas <gisle@ActiveState.com> Release 2.23 diff --git a/ext/Digest/MD5/MD5.pm b/ext/Digest/MD5/MD5.pm index 22366059e9..ece02dfbf2 100644 --- a/ext/Digest/MD5/MD5.pm +++ b/ext/Digest/MD5/MD5.pm @@ -3,7 +3,7 @@ package Digest::MD5; use strict; use vars qw($VERSION @ISA @EXPORT_OK); -$VERSION = '2.23'; # $Date: 2003/01/19 04:42:15 $ +$VERSION = '2.24'; # $Date: 2003/03/09 15:23:10 $ require Exporter; *import = \&Exporter::import; diff --git a/ext/Digest/MD5/MD5.xs b/ext/Digest/MD5/MD5.xs index f70acbb8fa..1888f754a6 100644 --- a/ext/Digest/MD5/MD5.xs +++ b/ext/Digest/MD5/MD5.xs @@ -1,4 +1,4 @@ -/* $Id: MD5.xs,v 1.35 2003/01/05 00:54:17 gisle Exp $ */ +/* $Id: MD5.xs,v 1.37 2003/03/09 15:20:43 gisle Exp $ */ /* * This library is free software; you can redistribute it and/or @@ -44,17 +44,26 @@ extern "C" { } #endif -#ifndef PATCHLEVEL +#ifndef PERL_VERSION # include <patchlevel.h> # if !(defined(PERL_VERSION) || (SUBVERSION > 0 && defined(PATCHLEVEL))) # include <could_not_find_Perl_patchlevel.h> # endif +# define PERL_REVISION 5 +# define PERL_VERSION PATCHLEVEL +# define PERL_SUBVERSION SUBVERSION #endif #if PATCHLEVEL <= 4 && !defined(PL_dowarn) #define PL_dowarn dowarn #endif +#ifdef G_WARN_ON + #define DOWARN (PL_dowarn & G_WARN_ON) +#else + #define DOWARN PL_dowarn +#endif + #ifdef SvPVbyte #if PERL_REVISION == 5 && PERL_VERSION < 7 /* SvPVbyte does not work in perl-5.6.1, borrowed version for 5.7.3 */ @@ -664,7 +673,7 @@ md5(...) PPCODE: MD5Init(&ctx); - if (PL_dowarn) { + if (DOWARN) { char *msg = 0; if (items == 1) { if (SvROK(ST(0))) { diff --git a/ext/Digest/MD5/t/files.t b/ext/Digest/MD5/t/files.t index e9e9d3b7f9..1af754f691 100644 --- a/ext/Digest/MD5/t/files.t +++ b/ext/Digest/MD5/t/files.t @@ -20,27 +20,27 @@ use Digest::MD5 qw(md5 md5_hex md5_base64); my $EXPECT; if (ord "A" == 193) { # EBCDIC $EXPECT = <<EOT; -aab6fda26844b46ca878f46394c52bb2 Changes +4ee4091bda2bb74fb2416c2fdb0c4d4a Changes 0565ec21b15c0f23f4c51fb327c8926d README -5d2a638a7323f5bd5b5c120c9330b99d MD5.pm -de2c149900efee0fbb39ad87dea68a43 MD5.xs +b00637894d2bd395ffda2fa84adefdfd MD5.pm +cd20b0f03df85e12d32c112311cba82f MD5.xs 276da0aa4e9a08b7fe09430c9c5690aa rfc1321.txt EOT } elsif ("\n" eq "\015") { # MacOS $EXPECT = <<EOT; -48ce3d9c310bd3173f6fe0a336f349cf Changes -53a0461b093f6c9d3e03d31f7133e62c README -7dcff59ab5cb7ad4998fb518047b2e59 MD5.pm -10542966f7609cb13816dc6a18527775 MD5.xs +0b95218ddeca76d2ccd6362b8e7c05a4 Changes +6c950a0211a5a28f023bb482037698cd README +f854bd4984ad0e73c483a49a28893c74 MD5.pm +f62fea72c62d50d14ebd825eb8bbb8b4 MD5.xs 754b9db19f79dbc4992f7166eb0f37ce rfc1321.txt EOT } else { # This is the output of: 'md5sum Changes README MD5.pm MD5.xs rfc1321.txt' $EXPECT = <<EOT; -d286d6c6a61e44e88d1deba9954ce37a Changes +d7b1bf11283114d1b765f433a5d7b447 Changes 6c950a0211a5a28f023bb482037698cd README -d31c9aefa1a9e40beda9fff1e1d9c02d MD5.pm -df178436ead9d354d63089fa0e01af27 MD5.xs +f854bd4984ad0e73c483a49a28893c74 MD5.pm +f62fea72c62d50d14ebd825eb8bbb8b4 MD5.xs 754b9db19f79dbc4992f7166eb0f37ce rfc1321.txt EOT } @@ -61,7 +61,7 @@ if ($@) { for (split /^/, $EXPECT) { my($md5hex, $file) = split ' '; my $base = $file; - print "# $base\n"; +# print "# $base\n"; if ($ENV{PERL_CORE}) { if ($file eq 'rfc1321.txt') { # Don't have it in core. print "ok ", ++$testno, " # Skip: PERL_CORE\n"; @@ -88,7 +88,9 @@ for (split /^/, $EXPECT) { next; } if ($ENV{MAC_MD5SUM}) { + require Encode; my $data = cat_file($file); + Encode::from_to($data, 'latin1', 'MacRoman'); print md5_hex($data), " $base\n"; next; } |