diff options
author | George Hazan <ghazan@miranda.im> | 2018-02-04 16:42:23 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-02-04 16:42:23 +0300 |
commit | 32cd89f64ef0449eac0ceea2ba9bc1aa36c5759b (patch) | |
tree | 5cb92407bb71893399210adb0d8dadcc53ab6dd6 /src | |
parent | 60a76a56531ceb2bb6d03add1de32ceeef832be9 (diff) |
the error code of db_event_get() should be checked
Diffstat (limited to 'src')
-rw-r--r-- | src/core/stdmsg/src/msgs.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/stdmsg/src/msgs.cpp b/src/core/stdmsg/src/msgs.cpp index 31e95c3db4..2933bbf669 100644 --- a/src/core/stdmsg/src/msgs.cpp +++ b/src/core/stdmsg/src/msgs.cpp @@ -246,7 +246,9 @@ static void RestoreUnreadMessageAlerts(void) DBEVENTINFO dbei = {};
dbei.cbBlob = 0;
- db_event_get(hDbEvent, &dbei);
+ if (db_event_get(hDbEvent, &dbei))
+ continue;
+
if (!(dbei.flags & (DBEF_SENT | DBEF_READ)) && (dbei.eventType == EVENTTYPE_MESSAGE || DbEventIsForMsgWindow(&dbei))) {
int windowAlreadyExists = Srmm_FindWindow(hContact) != nullptr;
if (windowAlreadyExists)
|