summaryrefslogtreecommitdiff
path: root/plugins/Scriver/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Scriver/src')
-rw-r--r--plugins/Scriver/src/msgs.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/Scriver/src/msgs.cpp b/plugins/Scriver/src/msgs.cpp
index d7c0f1ac32..e713c569cc 100644
--- a/plugins/Scriver/src/msgs.cpp
+++ b/plugins/Scriver/src/msgs.cpp
@@ -252,7 +252,8 @@ static void RestoreUnreadMessageAlerts(void)
for (MEVENT hDbEvent = db_event_firstUnread(hContact); hDbEvent; hDbEvent = db_event_next(hContact, hDbEvent)) {
DBEVENTINFO dbei = {};
dbei.cbBlob = 0;
- db_event_get(hDbEvent, &dbei);
+ if (db_event_get(hDbEvent, &dbei))
+ continue;
if ((dbei.flags & (DBEF_SENT | DBEF_READ)) || !DbEventIsMessageOrCustom(&dbei))
continue;