summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_archive.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2017-01-17 17:19:19 +0300
committerGeorge Hazan <ghazan@miranda.im>2017-01-17 17:19:19 +0300
commitb327ed7872ca83c3a4249039ba1a3d8dd3ece630 (patch)
tree5a4ae83dafab23f7832186b5dd0736611998f43c /protocols/JabberG/src/jabber_archive.cpp
parentfd7566b5de6b59bb18ff380cb1fa3f3f1089b70b (diff)
useless field DBEVENTINFO::cbSize removed
Diffstat (limited to 'protocols/JabberG/src/jabber_archive.cpp')
-rw-r--r--protocols/JabberG/src/jabber_archive.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/protocols/JabberG/src/jabber_archive.cpp b/protocols/JabberG/src/jabber_archive.cpp
index 32d5db407f..53165e64a1 100644
--- a/protocols/JabberG/src/jabber_archive.cpp
+++ b/protocols/JabberG/src/jabber_archive.cpp
@@ -94,7 +94,7 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
if (!hExistingDbEvent)
return FALSE;
- DBEVENTINFO dbeiExisting = { sizeof(dbeiExisting) };
+ DBEVENTINFO dbeiExisting = {};
db_event_get(hExistingDbEvent, &dbeiExisting);
DWORD dwEventTimeStamp = dbeiExisting.timestamp;
@@ -117,7 +117,6 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
return FALSE;
memset(&dbeiExisting, 0, sizeof(dbeiExisting));
- dbeiExisting.cbSize = sizeof(dbeiExisting);
db_event_get(hExistingDbEvent, &dbeiExisting);
dwEventTimeStamp = dbeiExisting.timestamp;
@@ -135,7 +134,6 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
// check for equal timestamps
if (dbei.timestamp == dwPreviousTimeStamp) {
memset(&dbeiExisting, 0, sizeof(dbeiExisting));
- dbeiExisting.cbSize = sizeof(dbeiExisting);
db_event_get(hPreviousDbEvent, &dbeiExisting);
if (dbei == dbeiExisting)
@@ -145,7 +143,6 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
hExistingDbEvent = db_event_next(hContact, hPreviousDbEvent);
while (hExistingDbEvent != NULL) {
memset(&dbeiExisting, 0, sizeof(dbeiExisting));
- dbeiExisting.cbSize = sizeof(dbeiExisting);
db_event_get(hExistingDbEvent, &dbeiExisting);
if (dbeiExisting.timestamp != dwPreviousTimeStamp) {
@@ -166,7 +163,6 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
// look back
while (hExistingDbEvent != NULL) {
memset(&dbeiExisting, 0, sizeof(dbeiExisting));
- dbeiExisting.cbSize = sizeof(dbeiExisting);
db_event_get(hExistingDbEvent, &dbeiExisting);
if (dbei.timestamp > dbeiExisting.timestamp) {
@@ -192,7 +188,6 @@ BOOL IsDuplicateEvent(MCONTACT hContact, DBEVENTINFO& dbei)
// look forward
while (hExistingDbEvent != NULL) {
memset(&dbeiExisting, 0, sizeof(dbeiExisting));
- dbeiExisting.cbSize = sizeof(dbeiExisting);
db_event_get(hExistingDbEvent, &dbeiExisting);
if (dbei.timestamp < dbeiExisting.timestamp) {
@@ -267,7 +262,7 @@ void CJabberProto::OnIqResultGetCollection(HXML iqNode, CJabberIqInfo*)
T2Utf szEventText(tszBody);
- DBEVENTINFO dbei = { sizeof(DBEVENTINFO) };
+ DBEVENTINFO dbei = {};
dbei.eventType = EVENTTYPE_MESSAGE;
dbei.szModule = m_szModuleName;
dbei.cbBlob = (DWORD)mir_strlen(szEventText)+1;