You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-29 08:21:15 +03:00
MCOL-5464: Fixes of bugs from ASAN warnings, part one (#2792)
* Fixes of bugs from ASAN warnings, part one * MQC as static library, with nifty counter for global map and mutex * Switch clang to 16 * link messageqcpp to execplan
This commit is contained in:
@ -591,6 +591,12 @@ uint64_t dateAdd(uint64_t time, const string& expr, IntervalColumn::interval_typ
|
||||
|
||||
if (-day < month_length[monthSave])
|
||||
{
|
||||
if (monthSave == 0)
|
||||
{
|
||||
monthSave = 12;
|
||||
tmpYear--;
|
||||
}
|
||||
|
||||
month--;
|
||||
monthSave--;
|
||||
|
||||
@ -613,6 +619,12 @@ uint64_t dateAdd(uint64_t time, const string& expr, IntervalColumn::interval_typ
|
||||
// BUG 5448 - changed from '==' to '<='
|
||||
if (day <= 0)
|
||||
{
|
||||
if (monthSave == 0)
|
||||
{
|
||||
monthSave = 12;
|
||||
tmpYear--;
|
||||
}
|
||||
|
||||
month--;
|
||||
monthSave--;
|
||||
|
||||
@ -635,6 +647,17 @@ uint64_t dateAdd(uint64_t time, const string& expr, IntervalColumn::interval_typ
|
||||
break;
|
||||
}
|
||||
|
||||
if (monthSave == 0)
|
||||
{
|
||||
monthSave = 12;
|
||||
tmpYear--;
|
||||
|
||||
if (isLeapYear(tmpYear))
|
||||
month_length[2] = 29;
|
||||
else
|
||||
month_length[2] = 28;
|
||||
}
|
||||
|
||||
month--;
|
||||
monthSave--;
|
||||
|
||||
|
Reference in New Issue
Block a user