diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2024-02-25 19:21:32 +0600 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2024-02-26 04:17:19 +0100 |
commit | 6cbb60688a90ee473563f5ee3f0950ed58eb41dc (patch) | |
tree | 133fdc9148ef25d5420c31003a6e14f72d86efde /odk | |
parent | db10d71c1a456abe2cd3feafdea7951fac99b3bd (diff) |
Replace an instance of MAX_PATH (plus some) with 32767
... which is the approximate maximum of Windows API, as documented in
https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation
Change-Id: Id166f425238e50d4131f72bcfd22b5268dea0c3f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163915
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'odk')
-rw-r--r-- | odk/source/unoapploader/win/unoapploader.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/odk/source/unoapploader/win/unoapploader.c b/odk/source/unoapploader/win/unoapploader.c index 7a4f9e98e3de..1b02775165b9 100644 --- a/odk/source/unoapploader/win/unoapploader.c +++ b/odk/source/unoapploader/win/unoapploader.c @@ -72,9 +72,7 @@ int WINAPI wWinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, if ( path != NULL ) { - wchar_t cmd[ - MY_LENGTH(L"\"") + MAX_PATH + - MY_LENGTH(L"\\unoinfo.exe\" c++")]; + wchar_t cmd[32767]; /* hopefully does not overflow */ cmd[0] = L'"'; wcscpy(cmd + 1, path); |