Don't ask to ask, just ask | |
PerlMonks |
Re: Testing the current directory with Cwd and File::Specby 0xbeef (Hermit) |
on Dec 07, 2005 at 00:21 UTC ( [id://514687]=note: print w/replies, xml ) | Need Help?? |
Here is another Cwd consideration. If the directory is a mounted filesystem, getcwd() (as the owner of the mounted filesystem) may return undefined if the owner has insufficient access to the underlying mount-point even if he has full access to the mounted filesystem. For example:
A command like tar will usually give an error like "tar: The getwd subroutine failed. Cannot open parent directory." This is useful to know in cases where the underlying stub directory's permissions affect programs relying on getcwd() e.g. /bin/pwd, tar etc. 0xbeef
In Section
Meditations
|
|