This is an automated email from the git hooks/post-receive script.

kanashiro-guest pushed a commit to branch master
in repository carton.

commit 680d8c923015671ec697069c97bcb9c0669b3af1
Author: Tatsuhiko Miyagawa <miyag...@bulknews.net>
Date:   Tue Jun 28 13:32:57 2011 -0400

    modules like Config.pm have no VERSION in corelist. Fixing is_core()
---
 lib/Carton.pm | 9 ++++++---
 xt/CLI.pm     | 2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/lib/Carton.pm b/lib/Carton.pm
index e981ff3..7676776 100644
--- a/lib/Carton.pm
+++ b/lib/Carton.pm
@@ -3,7 +3,7 @@ package Carton;
 use strict;
 use warnings;
 use 5.008_001;
-use version; our $VERSION = qv('v0.1_0');
+use version; our $VERSION = qv('v0.9.0');
 
 use Cwd;
 use Config qw(%Config);
@@ -173,9 +173,12 @@ sub is_core {
     $perl_version ||= $];
 
     require Module::CoreList;
-    my $core_ver = $Module::CoreList::version{$perl_version + 0}{$module};
+    my $is_core  = exists $Module::CoreList::version{$perl_version + 
0}{$module}
+        or return;
 
-    return $core_ver && version->new($core_ver) >= version->new($want_ver);
+    my $core_ver = $Module::CoreList::version{$perl_version + 0}{$module};
+    return 1 unless $want_ver;
+    return version->new($core_ver) >= version->new($want_ver);
 };
 
 sub walk_down_tree {
diff --git a/xt/CLI.pm b/xt/CLI.pm
index fcff297..0007dc2 100644
--- a/xt/CLI.pm
+++ b/xt/CLI.pm
@@ -49,7 +49,7 @@ sub run {
     my($self, @args) = @_;
     $self->{output} = '';
     $self->{system_output} = capture_merged {
-        $self->SUPER::run(@args);
+        eval { $self->SUPER::run(@args) };
     };
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-perl/packages/carton.git

_______________________________________________
Pkg-perl-cvs-commits mailing list
Pkg-perl-cvs-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-perl-cvs-commits

Reply via email to