sounding out long file path support

Christopher Faylor
Fri Nov 14 01:57:00 GMT 2003

On Fri, Nov 14, 2003 at 07:41:52AM +1100, Robert Collins wrote:
>	sounding you out about a series of patches from Ron Parker (and
>probably myself too) to give cygwin longer path support on NT
>platforms... Ron did email about this a while back, but no conversation
>ensued, so I'm reopening it to prevent any waste of time..

I've been sort of hoping to see patches for this.

>Where supported by the OS, use W variant file calls, combined with \\?\
>prefixed paths to allow access to (obscenely) long paths. This will
>allow some unix software that often passes the 280 character length to

I'm not wild about slowing down parts of cygwin where people are already
complaining about slowness but I guess I'll wait to see the patch.

>basic approach:
>- extend the PATH_MAX macro(s) to an arbitrary number - say 4K which is
>what linux uses.
>- Wrap all the file IO calls in cygwin in cygwin internal thunks, that
>will examine the host and use the current A series call, or the W series
>call if available. 
>- if a > 280 character path is handed to one of the thunks, and W calls
>are not available, return an appropriate error.

You'd also have to modify fpathconf.  I'm somewhat worried that a
program which thinks it is being compliant by using PATH_MAX could
suffer unexpected failures, though.


More information about the Cygwin-developers mailing list