summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorMikalaiR <nikolay.romanovich@narod.ru>2016-02-29 16:47:05 +0000
committerMikalaiR <nikolay.romanovich@narod.ru>2016-02-29 16:47:05 +0000
commitcfc52e743a79a7ee49e577b72b2f8ed44017d221 (patch)
tree6f4ef8b50937c83522bcc1620960361507e4518d /plugins
parent529d1a105104891edf8905cc3ecd1359a4e7c6aa (diff)
dbx_lmdb: small fix
git-svn-id: http://svn.miranda-ng.org/main/trunk@16380 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Dbx_mdb/src/dbevents.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/Dbx_mdb/src/dbevents.cpp b/plugins/Dbx_mdb/src/dbevents.cpp
index 30078625c7..d8ea2607a2 100644
--- a/plugins/Dbx_mdb/src/dbevents.cpp
+++ b/plugins/Dbx_mdb/src/dbevents.cpp
@@ -252,7 +252,9 @@ void CDbxMdb::FindNextUnread(const txn_ptr &txn, DBCachedContact *cc, DBEventSor
mdb_cursor_get(cursor, &key, &data, MDB_SET);
while (mdb_cursor_get(cursor, &key, &data, MDB_NEXT) == 0) {
DBEvent *dbe = (DBEvent*)data.mv_data;
- if (dbe->contactID == cc->contactID && !dbe->markedRead()) {
+ if (dbe->contactID != cc->contactID)
+ break;
+ if (!dbe->markedRead()) {
cc->dbc.dwFirstUnread = key2.dwEventId;
cc->dbc.tsFirstUnread = key2.ts;
return;