r54544 - /trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm
dmn at users.alioth.debian.org
dmn at users.alioth.debian.org
Fri Mar 19 07:03:56 UTC 2010
Author: dmn
Date: Fri Mar 19 07:03:43 2010
New Revision: 54544
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=54544
Log:
isolate /dev/null redirection of STDERR only around Module::Depends invocations
this makes visible a missing 'use Module::Depends'. Ouch!
Modified:
trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm
Modified: trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm?rev=54544&op=diff
==============================================================================
--- trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm (original)
+++ trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm Fri Mar 19 07:03:43 2010
@@ -20,6 +20,7 @@
use Debian::Version qw(deb_ver_cmp);
use File::Spec qw( catfile );
+use Module::Depends ();
use constant oldstable_perl_version => '5.8.8';
@@ -93,11 +94,14 @@
# try Module::Depends, but if that fails then
# fall back to Module::Depends::Intrusive.
- no warnings;
- local *STDERR;
- open( STDERR, ">/dev/null" );
my $finder = Module::Depends->new->dist_dir($dir);
- my $deps = $finder->find_modules;
+ my $deps;
+ do {
+ no warnings;
+ local *STDERR;
+ open( STDERR, ">/dev/null" );
+ $deps = $finder->find_modules;
+ };
my $error = $finder->error();
if ($error) {
@@ -113,7 +117,12 @@
if $verbose;
require Module::Depends::Intrusive;
$finder = Module::Depends::Intrusive->new->dist_dir($dir);
- $deps = $finder->find_modules;
+ do {
+ no warnings;
+ local *STDERR;
+ open( STDERR, ">/dev/null" );
+ $deps = $finder->find_modules;
+ };
if ( $finder->error ) {
if ($verbose) {
More information about the Pkg-perl-cvs-commits
mailing list