diff --git a/dlls/shell32/shfldr_unixfs.c b/dlls/shell32/shfldr_unixfs.c index 3cd69606f1b..b9906d8ed61 100644 --- a/dlls/shell32/shfldr_unixfs.c +++ b/dlls/shell32/shfldr_unixfs.c @@ -30,6 +30,7 @@ # include #endif #include +#include #define COBJMACROS #define NONAMELESSUNION @@ -314,7 +315,7 @@ static BOOL UNIXFS_build_subfolder_pidls(const char *path, LPITEMIDLIST **apidl, } /* Allocate space for fully qualified paths */ - pszFQPath = SHAlloc(strlen(path) + NAME_MAX); + pszFQPath = SHAlloc(strlen(path) + PATH_MAX); if (!pszFQPath) { WARN("SHAlloc failed!\n"); return FALSE;