8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-02-02 10:40:38 +01:00

Fix #6790 - MON$ATTACHMENTS.MON$TIMESTAMP is incorrect when DefaultTimeZone is

configured with time zone different from the server's default.
This commit is contained in:
Adriano dos Santos Fernandes 2021-05-03 15:38:03 -03:00
parent 5018dd6109
commit 8429c95795

View File

@ -797,13 +797,8 @@ bool TimeZoneUtil::decodeTimeStamp(const ISC_TIMESTAMP_TZ& timeStampTz, bool gmt
ISC_TIMESTAMP_TZ TimeZoneUtil::getCurrentSystemTimeStamp() ISC_TIMESTAMP_TZ TimeZoneUtil::getCurrentSystemTimeStamp()
{ {
TimeStamp now = TimeStamp::getCurrentTimeStamp(); auto tsTz = getCurrentGmtTimeStamp();
ISC_TIMESTAMP_TZ tsTz;
tsTz.utc_timestamp = now.value();
tsTz.time_zone = getSystemTimeZone(); tsTz.time_zone = getSystemTimeZone();
localTimeStampToUtc(tsTz);
return tsTz; return tsTz;
} }