summaryrefslogtreecommitdiff
path: root/plugins/SMS/src/functions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/SMS/src/functions.cpp')
-rw-r--r--plugins/SMS/src/functions.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/SMS/src/functions.cpp b/plugins/SMS/src/functions.cpp
index 3f125ac24e..0adc6aee21 100644
--- a/plugins/SMS/src/functions.cpp
+++ b/plugins/SMS/src/functions.cpp
@@ -183,7 +183,7 @@ MCONTACT HContactFromPhone(LPWSTR lpwszPhone, size_t dwPhoneSize)
{
if (lpwszPhone && dwPhoneSize) {
//check not already on list
- for (MCONTACT hContact = db_find_first(); hContact != NULL; hContact = db_find_next(hContact))
+ for (auto &hContact : contact_iter())
if (IsContactPhone(hContact, lpwszPhone, dwPhoneSize))
return hContact;
}