From: Dirk Lemstra Date: Sun, 2 Jun 2019 12:59:15 +0000 (+0200) Subject: Don't call GetShortPathNameW when NTLongPathsEnabled returns true. X-Git-Tag: 7.0.8-49~14 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=97e5a3f377489d8ac07c3ec543005514ed2d81c0;p=imagemagick Don't call GetShortPathNameW when NTLongPathsEnabled returns true. --- diff --git a/MagickCore/utility-private.h b/MagickCore/utility-private.h index c2f06e909..28c727d10 100644 --- a/MagickCore/utility-private.h +++ b/MagickCore/utility-private.h @@ -68,7 +68,7 @@ static inline wchar_t *create_wchar_path(const char *utf8) *wideChar; count=MultiByteToWideChar(CP_UTF8,0,utf8,-1,NULL,0); - if (count > MAX_PATH) + if ((count > MAX_PATH) && (NTLongPathsEnabled() == MagickFalse)) { char buffer[MagickPathExtent];