From c1c1a1b299ba6939da0476f4be1fff1333edcc5f Mon Sep 17 00:00:00 2001 From: Chris 'BinGOs' Williams Date: Sat, 2 Nov 2013 22:37:55 +0000 Subject: [PATCH] Update DB_File to CPAN version 1.830 [DELTA] 1.830 2 November 2013 * Memory leaks when failed to open db RT #89589 * DB_File uses AutoLoader for no reason RT #88258 --- Porting/Maintainers.pl | 2 +- cpan/DB_File/DB_File.pm | 8 ++------ cpan/DB_File/DB_File.xs | 3 +++ cpan/DB_File/Makefile.PL | 4 ++-- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/Porting/Maintainers.pl b/Porting/Maintainers.pl index 1564559..c3097b2 100755 --- a/Porting/Maintainers.pl +++ b/Porting/Maintainers.pl @@ -338,7 +338,7 @@ use File::Glob qw(:case); }, 'DB_File' => { - 'DISTRIBUTION' => 'PMQS/DB_File-1.829.tar.gz', + 'DISTRIBUTION' => 'PMQS/DB_File-1.830.tar.gz', 'FILES' => q[cpan/DB_File], 'EXCLUDED' => [ qr{^patches/}, diff --git a/cpan/DB_File/DB_File.pm b/cpan/DB_File/DB_File.pm index 67083d8..c00437c 100644 --- a/cpan/DB_File/DB_File.pm +++ b/cpan/DB_File/DB_File.pm @@ -9,7 +9,7 @@ package DB_File::HASHINFO ; -require 5.00404; +require 5.00504; use warnings; use strict; @@ -163,7 +163,7 @@ our ($db_version, $use_XSLoader, $splice_end_array_no_length, $splice_end_array, use Carp; -$VERSION = "1.829" ; +$VERSION = "1.830" ; $VERSION = eval $VERSION; # needed for dev releases { @@ -186,7 +186,6 @@ $DB_RECNO = new DB_File::RECNOINFO ; require Tie::Hash; require Exporter; -use AutoLoader; BEGIN { $use_XSLoader = 1 ; { local $SIG{__DIE__} ; eval { require XSLoader } ; } @@ -257,9 +256,6 @@ if ($use_XSLoader) else { bootstrap DB_File $VERSION } -# Preloaded methods go here. Autoload methods go after __END__, and are -# processed by the autosplit program. - sub tie_hash_or_array { my (@arg) = @_ ; diff --git a/cpan/DB_File/DB_File.xs b/cpan/DB_File/DB_File.xs index 5452917..83ba736 100644 --- a/cpan/DB_File/DB_File.xs +++ b/cpan/DB_File/DB_File.xs @@ -1497,7 +1497,10 @@ SV * sv ; } if (status) + { + db_close(RETVAL); // close **dbp handle to prevent mem.leak RETVAL->dbp = NULL ; + } } diff --git a/cpan/DB_File/Makefile.PL b/cpan/DB_File/Makefile.PL index 1beef32..d33e74f 100644 --- a/cpan/DB_File/Makefile.PL +++ b/cpan/DB_File/Makefile.PL @@ -4,8 +4,8 @@ use strict ; use ExtUtils::MakeMaker 5.16 ; use Config ; -die "DB_File needs Perl 5.004_05 or better. This is $]\n" - if $] <= 5.00404; +die "DB_File needs Perl 5.005_04 or better. This is $]\n" + if $] < 5.00504; my $VER_INFO ; my $LIB_DIR ; -- 2.7.4