5 ms·
> deep directory structure whose total path length exceeds 1GB [...] Oh, I didn't know Linux supports GB long path name. On Windows it's limited to something l
by habibur 5y ago
> deep directory structure whose total path length exceeds 1GB [...]
Oh, I didn't know Linux supports GB long path name. On Windows it's limited to something like MAX_PATH_LENGTH which was defined as 200+ chars when I worked on it.
- Already__Taken 5y agoWindows lifted that limit a few years ago
- paavohtl 5y agoAFAIK the limit has been lifted since Windows NT (so since the 90s), but only if you use the obscure NT path prefix (\\?\).
- magicalhippo 5y agoNot that obscure, it's been mentioned on MSDN for every relevant operation since before 2000.
- divingdragon 5y agoIIRC you still need to use a special flag to enable it, right?
- masklinn 5y agoThere are two things necessary for an application to use long paths: * the system must have LongPathsEnabled set (though it might be the default nowadays, not sure) * the application itself must have `{http://schemas.microsoft.com/SMI/2016/WindowsSettings}longPathAware http://schemas.microsoft.com/SMI/2016/WindowsSettings}longPa...` set in its manifest
- dragonwriter 5y ago> Windows lifted that limit a few years ago IIRC, its a mess because it was lifted inconsistently for different access methods (APIs, and as a consequence UI/CLI methods that depend on them), and at least for some in ways which also are or were dependent on how paths are expressed. So it is, or at least has historically been after it was first “lifted”, a minefield of inconsistent, surprising behaviors with plenty of gotchas if you didn’t treat it as if it were still a limit.
- formerly_proven 5y agoWindows goes to 260 chars, but the underlying system supports something like 64K, which means you can have files on Windows which are largely untouchable by built-in tools (Windows Explorer, file dialogs etc.)
- masklinn 5y agoWindows goes way beyond 260, but for BC purposes historically you needed UNC paths (and UNC-aware APIs?). Since W10 Anniversary Update, there is a setting to disable the MAX_PATH limitation in various APIs, but applications still have to opt into long path awareness via a manifest key.