On Fri, Oct 31, 2008 at 9:04 AM, Eric Blake wrote: > POSIX 200x (which is on track to be approved later this year) has modified > the requirements on realpath() that NULL be a universally accepted > argument.
Oh, good. > Not all vendors comply with this yet, but at some point, it > will no longer be a GNU extension, but a POSIX-mandated requirement that > realpath() be able to malloc its result. This is part of the overall > paradigm change in POSIX 200x that recognizes that it is legal to have > paths longer than PATH_MAX I haven't tested it, but IIRC, GNU's version doesn't currently support such paths, either. It allocates the buffer for you if you pass in NULL, but it still only allocates PATH_MAX bytes. Thanks for the info. Anything to improve that interaction is a welcome change. The idea of a "maximum path length" is demonstrably bogus, while string functions that take a destination buffer but no size parameter are just plain dangerous. -- Mark J. Reed <[EMAIL PROTECTED]> -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/