don't loop (UINT)-1 times if the section is not present, CID 445

svn path=/trunk/; revision=36764
This commit is contained in:
Kamil Hornicek
2008-10-15 18:59:47 +00:00
parent 149add092a
commit 4e58a2eaca
+3 -2
View File
@@ -26,14 +26,15 @@ static HWND hLangList;
static BOOL
GetSupportedCP(VOID)
{
UINT uiCPage, Count, Number;
UINT uiCPage, Number;
LONG Count;
INFCONTEXT infCont;
LPCPAGE lpCPage;
HANDLE hCPage;
CPINFOEX cpInfEx;
//TCHAR Section[MAX_PATH];
Count = (UINT) SetupGetLineCount(hIntlInf, _T("CodePages"));
Count = SetupGetLineCount(hIntlInf, _T("CodePages"));
if (Count <= 0) return FALSE;
for (Number = 0; Number < Count; Number++)