Commit d92fe2cb authored by Rob Shearman's avatar Rob Shearman Committed by Alexandre Julliard

shell32: Fix character count passed into lstrcpnA in SHGetDataFromIDListA.

parent 8aa36174
......@@ -1125,12 +1125,12 @@ HRESULT WINAPI SHGetDataFromIDListA(LPSHELLFOLDER psf, LPCITEMIDLIST pidl,
shortname = _ILGetSTextPointer(pidl);
if (filename)
lstrcpynA(pfd->cFileName, filename, MAX_PATH);
lstrcpynA(pfd->cFileName, filename, sizeof(pfd->cFileName));
else
pfd->cFileName[0] = '\0';
if (shortname)
lstrcpynA(pfd->cAlternateFileName, shortname, MAX_PATH);
lstrcpynA(pfd->cAlternateFileName, shortname, sizeof(pfd->cAlternateFileName));
else
pfd->cAlternateFileName[0] = '\0';
return NOERROR;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment