- fix enumeration of available time zones

svn path=/trunk/; revision=32626
This commit is contained in:
Johannes Anderwald 2008-03-09 15:34:13 +00:00
parent c1c402a4e6
commit 06471d3eb5

View file

@ -89,7 +89,7 @@ CreateTimeZoneList(VOID)
NULL,
NULL,
NULL);
if (lError != ERROR_SUCCESS && lError != ERROR_MORE_DATA)
if (lError == ERROR_NO_MORE_ITEMS)
break;
if (RegOpenKeyEx (hZonesKey,
@ -107,15 +107,18 @@ CreateTimeZoneList(VOID)
}
dwValueSize = 64 * sizeof(WCHAR);
if (RegQueryValueExW(hZoneKey,
lError = RegQueryValueExW(hZoneKey,
L"Display",
NULL,
NULL,
(LPBYTE)&Entry->Description,
&dwValueSize))
&dwValueSize);
if (lError != ERROR_SUCCESS)
{
RegCloseKey(hZoneKey);
break;
dwIndex++;
HeapFree(GetProcessHeap(), 0, Entry);
continue;
}
dwValueSize = 33 * sizeof(WCHAR);