Skip Menu |

This queue is for tickets about the PathTools CPAN distribution.

Report information
The Basics
Id: 17878
Status: rejected
Priority: 0/
Queue: PathTools

People
Owner: Nobody in particular
Requestors: rrwo [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 3.16
Fixed in: (no value)



Subject: ".." in absolute path from rel2abs
rel2abs returns files with ".." in them. I have a spec that requires paths not to have ".." in them. I am unable to use File::Spec to generate absolute paths. rel2abs("../bar/file","/foo") returns "/foo/../bar/file" rather than "/bar/file".
This is by design. See the note in the docs for canonpath(). If you need to resolve /x/.. sections in paths, have a look at Cwd::abspath(), which will consult the filesystem so it can do it correctly. -Ken