diff options
Diffstat (limited to 'plugins/CountryFlags/src/extraimg.cpp')
-rw-r--r-- | plugins/CountryFlags/src/extraimg.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/plugins/CountryFlags/src/extraimg.cpp b/plugins/CountryFlags/src/extraimg.cpp index ab109230ce..99a737cfd5 100644 --- a/plugins/CountryFlags/src/extraimg.cpp +++ b/plugins/CountryFlags/src/extraimg.cpp @@ -64,21 +64,15 @@ static void CALLBACK SetExtraImage(HANDLE hContact) // always call in context of main thread
static void RemoveExtraImages(void)
{
- HANDLE hContact = db_find_first();
- while (hContact != NULL) {
+ for (HANDLE hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
ExtraIcon_Clear(hExtraIcon, hContact);
- hContact = db_find_next(hContact);
- }
}
// always call in context of main thread
static void EnsureExtraImages(void)
{
- HANDLE hContact = db_find_first();
- while (hContact != NULL) {
+ for (HANDLE hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
SetExtraImage(hContact);
- hContact = db_find_next(hContact);
- }
}
static void CALLBACK UpdateExtraImages(LPARAM lParam)
|