diff --git a/src/jrd/SysFunction.cpp b/src/jrd/SysFunction.cpp index e46db6e8ee..0088dfc0c0 100644 --- a/src/jrd/SysFunction.cpp +++ b/src/jrd/SysFunction.cpp @@ -2802,9 +2802,10 @@ dsc* evlDateAdd(thread_db* tdbb, const SysFunction* function, const NestValueArr ERR_post(Arg::Gds(rangeExceededStatus)); tm times; - timestamp.decode(×); + int fractions; + timestamp.decode(×, &fractions); times.tm_year += quantity; - timestamp.encode(×); + timestamp.encode(×, fractions); int day = times.tm_mday; timestamp.decode(×); @@ -2820,7 +2821,8 @@ dsc* evlDateAdd(thread_db* tdbb, const SysFunction* function, const NestValueArr ERR_post(Arg::Gds(rangeExceededStatus)); tm times; - timestamp.decode(×); + int fractions; + timestamp.decode(×, &fractions); int md[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; @@ -2855,7 +2857,7 @@ dsc* evlDateAdd(thread_db* tdbb, const SysFunction* function, const NestValueArr else if (times.tm_mday < 1) times.tm_mday = 1; - timestamp.encode(×); + timestamp.encode(×, fractions); } break;