Skip Menu |
 

This queue is for tickets about the File-Spec CPAN distribution.

Report information
The Basics
Id: 4129
Status: new
Priority: 0/
Queue: File-Spec

People
Owner: Nobody in particular
Requestors: chris [...] clotho.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.86
Fixed in: (no value)



Subject: Missing undef check in File::Spec::Unix::canonpath
Download (untitled) / with headers
text/plain 667b
With warnings turned on, File::Spec::Unix::canonpath() spews many warnings when passed an undef path. The following patch causes this method to simply return undef instead of trying to perform regexes on the undef value. --- Unix.pm.orig 2003-10-16 10:08:56.000000000 -0500 +++ Unix.pm 2003-10-16 10:10:05.000000000 -0500 @@ -35,6 +35,8 @@ sub canonpath { my ($self,$path) = @_; + return undef unless (defined $path); + # Handle POSIX-style node names beginning with double slash (qnx, nto) # Handle network path names beginning with double slash (cygwin) # (POSIX says: "a pathname that begins with two successive slashes


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.