PathFindNextComponent: return pointer to NULL and not NULL.
This commit is contained in:
parent
d9ac53f15a
commit
4c5af80c6a
|
@ -1242,7 +1242,8 @@ BOOL FILEDLG95_OnOpen(HWND hwnd)
|
|||
WCHAR lpwstrTemp[MAX_PATH];
|
||||
DWORD dwEaten, dwAttributes;
|
||||
|
||||
if ((lpszTemp = COMDLG32_PathFindNextComponentA(lpszTemp)))
|
||||
lpszTemp = COMDLG32_PathFindNextComponentA(lpszTemp);
|
||||
if (*lpszTemp)
|
||||
lstrcpynAtoW(lpwstrTemp, lpszTemp1, lpszTemp - lpszTemp1);
|
||||
else
|
||||
{
|
||||
|
|
|
@ -2177,15 +2177,17 @@ BOOL WINAPI PathCanonicalizeW(LPWSTR pszBuf, LPCWSTR pszPath)
|
|||
|
||||
/*************************************************************************
|
||||
* PathFindNextComponentA
|
||||
*
|
||||
* Windows returns a pointer NULL (BO 000605)
|
||||
*/
|
||||
LPSTR WINAPI PathFindNextComponentA(LPCSTR pszPath)
|
||||
{
|
||||
while( *pszPath )
|
||||
{
|
||||
if(*pszPath++=='\\')
|
||||
return (LPSTR)((*pszPath)? pszPath : NULL);
|
||||
return pszPath;
|
||||
}
|
||||
return NULL;
|
||||
return pszPath;
|
||||
}
|
||||
|
||||
/*************************************************************************
|
||||
|
@ -2196,9 +2198,9 @@ LPWSTR WINAPI PathFindNextComponentW(LPCWSTR pszPath)
|
|||
while( *pszPath )
|
||||
{
|
||||
if(*pszPath++=='\\')
|
||||
return (LPWSTR)((*pszPath)? pszPath : NULL);
|
||||
return pszPath;
|
||||
}
|
||||
return NULL;
|
||||
return pszPath;
|
||||
}
|
||||
|
||||
/*************************************************************************
|
||||
|
|
Loading…
Reference in New Issue