From b19a3f3ed6afec2e4e30562ec55d53c796bd8154 Mon Sep 17 00:00:00 2001 From: "METANEOCORTEX\\Kotti" Date: Wed, 1 Dec 2021 12:42:05 +0100 Subject: [PATCH] +fix: find file extension --- src/PathLib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PathLib.c b/src/PathLib.c index 4dc3f6215..73e3c4df4 100644 --- a/src/PathLib.c +++ b/src/PathLib.c @@ -1168,7 +1168,7 @@ LPCWSTR PTHAPI Path_FindExtension(const HPATHL hpth) ///PathXCchFindExtension(StrgGet(hstr), StrgGetAllocLength(hstr), &pext); LPCWSTR pfile = Path_FindFileName(hpth); - LPWSTR const pdot = pfile ? wcschr(pfile, L'.') : NULL; + LPWSTR const pdot = pfile ? wcsrchr(pfile, L'.') : NULL; StrgSanitize(hstr); return pdot ? pdot : &wbuf[StrgGetLength(hstr)];