Brian De Wolf <[email protected]> wrote:

> Is it crazy to ask for getcwd's behavior to be changed?  It's
> technically allowed by POSIX to fail like this (which I suspect is to
> allow for naive implementations that have to walk the filesystem), but
> there doesn't seem to be an alternative for a process that wants to
> validate its cwd.

POSIX does not allow to do this:

The getcwd() function shall fail if:
...
[EACCES]
    Search permission was denied for the current directory, or read or search 
permission was denied for a directory above the current directory in the file 
hierarchy.

You may like to send a bug report against that on "austingroupbugs".

Your wish would require that "shall" is replaced by "may".

Jörg

-- 
 EMail:[email protected]                    (home) Jörg Schilling D-13353 Berlin
    [email protected] (work) Blog: http://schily.blogspot.com/
 URL: http://cdrecord.org/private/ http://sf.net/projects/schilytools/files/'

------------------------------------------
illumos-discuss
Archives: 
https://illumos.topicbox.com/groups/discuss/discussions/T1bf578bf66b8b8b0-Mcb117ceb4efd74ac3fbeca06
Powered by Topicbox: https://topicbox.com

Reply via email to