Find all directories and make sure found entries are directories
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@2666 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
63a1f7a0e3
commit
9adf1acb50
2 changed files with 19 additions and 12 deletions
|
@ -334,9 +334,13 @@ void AddFolderFromReg(HKEY rootKey)
|
||||||
RegCloseKey(hKey);
|
RegCloseKey(hKey);
|
||||||
}
|
}
|
||||||
|
|
||||||
lstrcat(buf, "\\*.");
|
lstrcat(buf, "\\*.*");
|
||||||
hSearch = FindFirstFile(buf, &FileData);
|
hSearch = FindFirstFile(buf, &FileData);
|
||||||
if (hSearch != INVALID_HANDLE_VALUE) do
|
if (hSearch != INVALID_HANDLE_VALUE)
|
||||||
|
{
|
||||||
|
do
|
||||||
|
{
|
||||||
|
if (FileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
|
||||||
{
|
{
|
||||||
if (*(WORD*)FileData.cFileName != *(WORD*)".")
|
if (*(WORD*)FileData.cFileName != *(WORD*)".")
|
||||||
{
|
{
|
||||||
|
@ -349,5 +353,8 @@ void AddFolderFromReg(HKEY rootKey)
|
||||||
(LPARAM)ExtractAssociatedIcon(g_hInstance, FileData.cFileName, (WORD*)&idx));*/
|
(LPARAM)ExtractAssociatedIcon(g_hInstance, FileData.cFileName, (WORD*)&idx));*/
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} while (FindNextFile(hSearch, &FileData));
|
}
|
||||||
|
} while (FindNextFile(hSearch, &FileData));
|
||||||
|
FindClose(hSearch);
|
||||||
|
}
|
||||||
}
|
}
|
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue