Subject: | A fix to CPAN::HandleConfig.pm |
Date: | Sun, 27 Dec 2009 19:17:30 +0800 |
To: | bug-CPAN [...] rt.cpan.org |
From: | Shu Cho <neatcho [...] gmail.com> |
Hi,
I found a bug w/ CPAN::HandleConfig.pm. At CPAN Shell, after input the
`o conf help` command, an error occured. Here's a sample command
session.
cpan[1]> o conf help
...
Catching error: "Panic: could not configure CPAN.pm for args
[]. Giving up. at /Users/shucho/perl5/lib/perl5/CPAN/HandleConfig.pm
line 128.\cJ" at /Users/shucho/perl5/lib/perl5/CPAN.pm line 391
CPAN::shell() called at /Users/shucho/perl5/bin/cpan line 198
After a little research, I found that `HandleConfig::help` subroutine
returned a falsy value (undef), then it caused the panic message
spitting.
Here's my easy fix, hope that help.
--- HandleConfig.pm 2009-12-02 09:11:24.000000000 +0800
+++ HandleConfig_fix.pm 2009-12-02 09:12:10.000000000 +0800
@@ -633,7 +633,7 @@
o conf inhibit_startup_message 1
]);
- undef; #don't reprint CPAN::Config
+ 1; #don't reprint CPAN::Config
}
sub cpl {
Oh, BTW, the CPAN distro version number is 1.9402.
Thanks,
Shu Cho