nIconIndex == -1 should return nr of available icons, not 0.

This commit is contained in:
Marcus Meissner 2000-01-29 20:59:31 +00:00 committed by Alexandre Julliard
parent d327fcbdb3
commit 8b466e0ce8

View File

@ -220,7 +220,7 @@ HICON WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nIco
TRACE("(file %s,start %d,extract %d\n", lpszExeFileName, nIconIndex, n);
if( hFile == HFILE_ERROR || !n )
if( hFile == HFILE_ERROR || (nIconIndex!=-1 && !n) )
return hRet;
sig = SHELL_GetResourceTable(hFile,&pData);