From 3d30ed65f9e226b7b183b23ce5dba435ec491f0b Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 10 Jan 2025 18:28:28 +0300 Subject: DBEVENTINFO::timestamp to become 64-bit integer --- plugins/Variables/src/parse_miranda.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'plugins/Variables/src/parse_miranda.cpp') diff --git a/plugins/Variables/src/parse_miranda.cpp b/plugins/Variables/src/parse_miranda.cpp index 845dfc33ae..7e87c23ec5 100644 --- a/plugins/Variables/src/parse_miranda.cpp +++ b/plugins/Variables/src/parse_miranda.cpp @@ -442,9 +442,9 @@ static MEVENT findDbEvent(MCONTACT hContact, MEVENT hDbEvent, int flags) hSearchEvent = findDbEvent(hSearchContact, NULL, flags); dbe.cbBlob = 0; if (!db_event_get(hSearchEvent, &dbe)) { - if ((dbe.timestamp < matchTimestamp) || (matchTimestamp == 0)) { + if ((dbe.getUnixtime() < matchTimestamp) || (matchTimestamp == 0)) { hMatchEvent = hSearchEvent; - matchTimestamp = dbe.timestamp; + matchTimestamp = dbe.getUnixtime(); } } } @@ -455,9 +455,9 @@ static MEVENT findDbEvent(MCONTACT hContact, MEVENT hDbEvent, int flags) hSearchEvent = findDbEvent(hSearchContact, NULL, flags); dbe.cbBlob = 0; if (!db_event_get(hSearchEvent, &dbe)) { - if ((dbe.timestamp > matchTimestamp) || (matchTimestamp == 0)) { + if ((dbe.getUnixtime() > matchTimestamp) || (matchTimestamp == 0)) { hMatchEvent = hSearchEvent; - matchTimestamp = dbe.timestamp; + matchTimestamp = dbe.getUnixtime(); } } } @@ -466,14 +466,14 @@ static MEVENT findDbEvent(MCONTACT hContact, MEVENT hDbEvent, int flags) else if (flags & DBE_NEXT) { dbe.cbBlob = 0; if (!db_event_get(hDbEvent, &dbe)) { - priorTimestamp = dbe.timestamp; + priorTimestamp = dbe.getUnixtime(); for (auto &hSearchContact : Contacts()) { hSearchEvent = findDbEvent(hSearchContact, hDbEvent, flags); dbe.cbBlob = 0; if (!db_event_get(hSearchEvent, &dbe)) { - if (((dbe.timestamp < matchTimestamp) || (matchTimestamp == 0)) && (dbe.timestamp > priorTimestamp)) { + if (((dbe.getUnixtime() < matchTimestamp) || (matchTimestamp == 0)) && (dbe.getUnixtime() > priorTimestamp)) { hMatchEvent = hSearchEvent; - matchTimestamp = dbe.timestamp; + matchTimestamp = dbe.getUnixtime(); } } } @@ -482,14 +482,14 @@ static MEVENT findDbEvent(MCONTACT hContact, MEVENT hDbEvent, int flags) } else if (flags & DBE_PREV) { if (!db_event_get(hDbEvent, &dbe)) { - priorTimestamp = dbe.timestamp; + priorTimestamp = dbe.getUnixtime(); for (auto &hSearchContact : Contacts()) { hSearchEvent = findDbEvent(hSearchContact, hDbEvent, flags); dbe.cbBlob = 0; if (!db_event_get(hSearchEvent, &dbe)) { - if (((dbe.timestamp > matchTimestamp) || (matchTimestamp == 0)) && (dbe.timestamp < priorTimestamp)) { + if (((dbe.getUnixtime() > matchTimestamp) || (matchTimestamp == 0)) && (dbe.getUnixtime() < priorTimestamp)) { hMatchEvent = hSearchEvent; - matchTimestamp = dbe.timestamp; + matchTimestamp = dbe.getUnixtime(); } } } -- cgit v1.2.3