Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATH_MAX vs. _PC_PATH_MAX vs. POSIX (was Re: PATCH: tail-dropping in files module mkdir)



} > The definition of pathconf(dir, _PC_PATH_MAX) is inherently incompatible
} > with the definition of the PATH_MAX constant.

I just found my 1991 copy of ORA's POSIX Programmer's Guide.  It says
specifically:

-----------------------

[...]

_PC_PATH_MAX   The maximum lenght of a relative pathname when this direc-
               tory is the working directory; that is, the number of
	       characters that may be appended to path and still have a
	       valid pathname.

[...]

Notes:

    The value returned by _PC_PATH_MAX is not useful for allocating storage.
    Files with paths longer than _PC_PATH_MAX may exist.

-----------------------

So I think pathconf() is of approximately zero use to zsh, at least for
_PC_PATH_MAX, and we should just rip zpathmax() out again.  I apologize
for helping lead us down this rathole.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com

Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net   



Messages sorted by: Reverse Date, Date, Thread, Author