From: Daniel Stone Date: Thu, 26 Mar 2020 13:01:58 +0000 (+0000) Subject: util/test: Use MAX_PATH on Windows X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=bc98de4d14f9c099e47a7de6efc3766823ca3f54;p=mesa.git util/test: Use MAX_PATH on Windows Windows provides MAX_PATH rather than PATH_MAX for the maximum allowable path length. This is not a limit on the length of filename which can exist on the filesystem, but a length on the length of path which can be passed to Win32 API calls. Signed-off-by: Daniel Stone Reviewed-by: Eric Engestrom Fixes: f8f1413070a ("util/u_process: add util_get_process_exec_path") Part-of: --- diff --git a/src/util/process_test.c b/src/util/process_test.c index 708c2766eb9..00703df6034 100644 --- a/src/util/process_test.c +++ b/src/util/process_test.c @@ -31,6 +31,11 @@ #include #include +#if DETECT_OS_WINDOWS && !defined(PATH_MAX) +#include +#define PATH_MAX MAX_PATH +#endif + bool error = false; static void