Bug 278306 - Cleanup comparison in GRE_GetCurrentProcessDirectory.
r=dougt p=116057@bacon.qcc.mass.edu (Justin Wood) git-svn-id: svn://10.0.0.236/trunk@167831 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -133,7 +133,7 @@ GRE_GetCurrentProcessDirectory(char* buffer)
|
||||
|
||||
#ifdef XP_WIN
|
||||
DWORD bufLength = ::GetModuleFileName(0, buffer, MAXPATHLEN);
|
||||
if (bufLength == 0 || bufLength >= MAXPATHLEN)
|
||||
if (bufLength == 0 || bufLength == MAXPATHLEN)
|
||||
return PR_FALSE;
|
||||
// chop of the executable name by finding the rightmost backslash
|
||||
unsigned char* lastSlash = _mbsrchr((unsigned char*) buffer, '\\');
|
||||
|
||||
Reference in New Issue
Block a user