shlwapi: Avoid reading past the pointer in PathCreateFromUrlW (valgrind).
This commit is contained in:
parent
1f713cc567
commit
9dacce1b4e
|
@ -3377,7 +3377,7 @@ HRESULT WINAPI PathCreateFromUrlW(LPCWSTR pszUrl, LPWSTR pszPath,
|
||||||
len = src - pszUrl;
|
len = src - pszUrl;
|
||||||
StrCpyNW(dst, pszUrl, len + 1);
|
StrCpyNW(dst, pszUrl, len + 1);
|
||||||
dst += len;
|
dst += len;
|
||||||
if (isalphaW(src[1]) && (src[2] == ':' || src[2] == '|'))
|
if (*src && isalphaW(src[1]) && (src[2] == ':' || src[2] == '|'))
|
||||||
{
|
{
|
||||||
/* 'Forget' to add a trailing '/', just like Windows */
|
/* 'Forget' to add a trailing '/', just like Windows */
|
||||||
src++;
|
src++;
|
||||||
|
|
Loading…
Reference in New Issue