dll basename starts after \

This commit is contained in:
Xiaoqiang Wang
2020-05-13 20:29:27 +02:00
parent eded1dbd7b
commit 99192cfe68
+1 -1
View File
@@ -780,7 +780,7 @@ static void registerExternalModules()
if (!GetModuleFileName(hMods[i], name, MAX_PATH)) continue; /* no library name */
name[sizeof(name)-1] = 0; /* WinXP may not terminate the string */
p = strrchr(name, '\\'); /* find file name part in "<location>/<module>.dll" */
if (p) { location = name; } else p=name; /* find end of "<location>\\" (if exists) */
if (p) { location = name; p++; } else p=name; /* find end of "<location>\\" (if exists) */
symname = p;
p = strchr(symname, '.'); /* find ".dll" */
if (p == NULL) p = symname + strlen(symname); /* no file extension ? */