View Issue Details

IDProjectCategoryView StatusLast Update
0001273OpenMPTGeneralpublic2022-06-09 13:37
ReporterSaga Musix Assigned To 
PrioritynormalSeverityfeatureReproducibilityN/A
Status newResolutionopen 
Target VersionOpenMPT 1.?? (long term goals) 
Summary0001273: Enable long path awareness
Description

Windows 10 supports paths longer than MAX_PATH for a selected number of APIs, described here: https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file#enable-long-paths-in-windows-10-version-1607-and-later

We should review if all code paths invoking those functions are not limited by MAX_PATH (quite a lot, if not all, usages of those APIs should already use dynamically-sized vectors) and then enable the option in our manifest.

TagsNo tags attached.
Has the bug occurred in previous versions?
Tested code revision (in case you know it)

Relationships

related to 0001555 resolvedmanx bump minimum requirements to Windows 10 1903 (Build 18362) for Windows 10 builds 

Activities

Saga Musix

Saga Musix

2019-10-15 20:05

administrator   ~0004110

  • There is some usage of GetCurrentDirectory, GetFullPathName and GetLongPathName with a fixed array size of 2048 in unrar; this can probably be ignored, we don't extract to disk

We do use MAX_PATH in various other places but from what I can see, they are all limited by the usage of Shell functions, which are still limited to MAX_PATH even when declaring this manifest entry. Sadly even the COM counterparts of some shell functions exhibit the same limitations.

From that perspective, it should be safe to turn on this feature.

manx

manx

2019-10-18 07:07

administrator   ~0004111

For future development, we should also review how std::filesystem handles long path names:

  • is it compatible with long path awareness?
  • does it prepend \\?\ to long paths where necessary? if not, we should probably report this as a bug.
manx

manx

2019-11-08 15:23

administrator   ~0004143

is it compatible with long path awareness?

probably

does it prepend \?\ to long paths where necessary? if not, we should probably report this as a bug.

it does not

manx

manx

2019-11-08 15:25

administrator   ~0004144

According to documentation long-path-awareness depends on a registry setting. Are we aware whether any known Windows version actually sets this registry setting, or is this purely a user setting for now?
In the latter case, I see little use in enabling support.

manx

manx

2019-11-08 15:37

administrator   ~0004145

IFF some Windows 10 version automatically sets the registry key, we might add the manifest for builds requiring this particular Windows 10 version and remove \\?\prefixing from this build completely. Otherwise, long-path-awareness does little but introduce another run-time variable that requires testing.

Issue History

Date Modified Username Field Change
2019-10-15 19:55 Saga Musix New Issue
2019-10-15 19:57 Saga Musix Description Updated
2019-10-15 20:05 Saga Musix Note Added: 0004110
2019-10-18 07:07 manx Note Added: 0004111
2019-11-08 15:23 manx Note Added: 0004143
2019-11-08 15:25 manx Note Added: 0004144
2019-11-08 15:37 manx Note Added: 0004145
2019-11-08 15:37 manx Target Version => OpenMPT 1.?? (long term goals)
2022-06-09 13:37 manx Relationship added related to 0001555