On Apr 23, 2010, at 09:44:46 +0200, casper....@sun.com wrote:

>> re: using a sh implementation that doesn't set PWD
>> from posix:
>> 
>> PWD
>> This variable shall represent an absolute pathname of the
>> current working directory. It shall not contain any
>> components that are dot or dot-dot. The value is set by the
>> cd utility, and by the sh utility during initialization.
>> 
>> if the shell runs any command then PWD will be in that command's environment
>> unless it is explicitly unset before the command is executed
> 
> 
> Is it proper for PWD to contain "/bin" when the actual absolute
> pathname of the directory in question in "/usr/bin"?

Hi Casper,

When symlinks are involved, there can be multiple absolute pathnames
naming a file.  If you invoke cd with the -P option when changing to
a new directory, the standard requires PWD to be set an absolute
pathname of the new current working directory which does not contain
any components with the filenames "." or ".." AND does not contain
any components naming a symbolic link.

 - Don

> Casper

_______________________________________________
ksh93-integration-discuss mailing list
ksh93-integration-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/ksh93-integration-discuss

Reply via email to