Fix GetPathDirectory for paths containing '\'

This commit is contained in:
palana 2014-09-12 20:20:36 +02:00
parent 2ca9f89e95
commit a484a72f93

View File

@ -294,7 +294,7 @@ String GetPathDirectory(CTSTR lpPath)
CTSTR lpDirectoryEnd = srchr(lpPath, '/'); CTSTR lpDirectoryEnd = srchr(lpPath, '/');
if(!lpDirectoryEnd) if(!lpDirectoryEnd)
lpDirectoryEnd = srchr(lpPath, '/'); lpDirectoryEnd = srchr(lpPath, '\\');
if(lpDirectoryEnd) if(lpDirectoryEnd)
nDirectoryEnd = (int)((((UPARAM)lpDirectoryEnd)-((UPARAM)lpPath))/sizeof(TCHAR)); nDirectoryEnd = (int)((((UPARAM)lpDirectoryEnd)-((UPARAM)lpPath))/sizeof(TCHAR));