26 Mar
2025
26 Mar
'25
10:35 a.m.
Zhiyi Zhang (@zhiyi) commented about dlls/kernel32/tests/file.c:
+ } + trace("in registry LongPathsEnabled: %ld\n", LongPathEnabled); + } + return LongPathEnabled == 1; +} + +static BOOL is_app_enabled_long_path(void) +{ + static WCHAR buffer[10] = { 0 }; + static const WCHAR trueW[] = {'t','r','u','e',0}; + + if (buffer[0] == 0) + { + BOOL ret; + SIZE_T size = 0xdead; + static const WCHAR longPathAwareW[] = {'l','o','n','g','P','a','t','h','A','w','a','r','e',0}; Let's use wide-char literal L"longPathAware" instead. Same for other places. And let's move variable declarations to the top of the function.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/7540#note_99115