Skip Menu |

This queue is for tickets about the Perl-Dist-Strawberry CPAN distribution.

Report information
The Basics
Id: 44584
Status: resolved
Priority: 0/
Queue: Perl-Dist-Strawberry

People
Owner: csjewell [...] cpan.org
Requestors: krishnoid+perl+pig [...] wapacut.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 2.00
Fixed in: (no value)



Subject: PPM.pm:InstallPackage() bug triggered if $ENV{HOME} valid
Strawberry perl portable 5.10 (release compiled at Feb 23 2009) PPM.pm's InstallPackage() downloads and unpacks a package, and then looks like it tries to chdir(undef) and falls back to chdir($ENV {HOME}). If $ENV{HOME} is set, the rest of the install fails; if not, the chdir fails and installation proceeds as normal. See http:// www.perlfoundation.org/perl5/index.cgi?ppm , under 'Gotchas'. Reproduce: in cmd.exe, set HOME=<some valid value>, then cd to <strawberry-perl-portable-top>\perl\bin, and run .\ppm.bat install <package> Workaround: set HOME= before running ppm.bat.
On Wed Mar 25 20:03:57 2009, KRISHPL wrote: Show quoted text
> Strawberry perl portable 5.10 (release compiled at Feb 23 2009) > PPM.pm's InstallPackage() downloads and unpacks a package, and then > looks like it tries to chdir(undef) and falls back to chdir($ENV > {HOME}). If $ENV{HOME} is set, the rest of the install fails; if not, > the chdir fails and installation proceeds as normal. See http:// > www.perlfoundation.org/perl5/index.cgi?ppm , under 'Gotchas'. > > Reproduce: in cmd.exe, set HOME=<some valid value>, then cd to > <strawberry-perl-portable-top>\perl\bin, and run .\ppm.bat install > <package> > Workaround: set HOME= before running ppm.bat.
IMO: This should use $ENV{HOME} // $ENV{USERPROFILE}. I may fix this for October 2009... stay tuned.
I encountered it in 5.8.9.3. At line 387 in C:\strawberry\perl\vendor\lib\PPM.pm, $1 becomes empty and chdir(undef) happens as KRISHPL writing. It seems to need to use a named variable instead of $1. Attached file is diff output of my modification.
379a380 > my $tarzip_dir; 381a383 > $tarzip_dir = $1; 385a388 > $tarzip_dir = $1; 387c390 < chdir($1); --- > chdir($tarzip_dir);
Pstched in r11370, will be fully fixed when the April 2009 versions arrive.