diff options
author | George Hazan <ghazan@miranda.im> | 2017-01-17 17:19:19 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2017-01-17 17:19:19 +0300 |
commit | b327ed7872ca83c3a4249039ba1a3d8dd3ece630 (patch) | |
tree | 5a4ae83dafab23f7832186b5dd0736611998f43c /plugins/Msg_Export | |
parent | fd7566b5de6b59bb18ff380cb1fa3f3f1089b70b (diff) |
useless field DBEVENTINFO::cbSize removed
Diffstat (limited to 'plugins/Msg_Export')
-rwxr-xr-x | plugins/Msg_Export/src/options.cpp | 2 | ||||
-rwxr-xr-x | plugins/Msg_Export/src/utils.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/plugins/Msg_Export/src/options.cpp b/plugins/Msg_Export/src/options.cpp index 995ff36544..dc40c7c1cd 100755 --- a/plugins/Msg_Export/src/options.cpp +++ b/plugins/Msg_Export/src/options.cpp @@ -64,7 +64,7 @@ public: hUser = hU;
hDbEvent = hDBE;
- DBEVENTINFO dbei = { sizeof(dbei) };
+ DBEVENTINFO dbei = {};
db_event_get(hDbEvent, &dbei);
time = dbei.timestamp;
}
diff --git a/plugins/Msg_Export/src/utils.cpp b/plugins/Msg_Export/src/utils.cpp index 6deb7aaccb..351a907e7c 100755 --- a/plugins/Msg_Export/src/utils.cpp +++ b/plugins/Msg_Export/src/utils.cpp @@ -1105,7 +1105,7 @@ void ExportDBEventInfo(MCONTACT hContact, DBEVENTINFO &dbei) DWORD uin = *((PDWORD)(dbei.pBlob));
int n = mir_snwprintf(szTemp, L"%d", uin);
if (bWriteTextToFile(hFile, szTemp, bWriteUTF8Format, n)) {
- char *pszEnd = (char *)(dbei.pBlob + dbei.cbSize);
+ char *pszEnd = (char *)(dbei.pBlob + sizeof(dbei));
for (int i = 0; i < nStringCount && pszCurBlobPos < pszEnd; i++) {
if (*pszCurBlobPos) {
if (!bWriteNewLine(hFile, nIndent) ||
@@ -1214,7 +1214,7 @@ int nExportEvent(WPARAM hContact, LPARAM hDbEvent) if (!db_get_b(hContact, MODULE, "EnableLog", 1))
return 0;
- DBEVENTINFO dbei = { sizeof(dbei) };
+ DBEVENTINFO dbei = {};
int nSize = db_event_getBlobSize(hDbEvent);
if (nSize > 0) {
dbei.cbBlob = nSize;
|