1
0
mirror of https://github.com/MariaDB/server.git synced 2026-01-06 05:22:24 +03:00

lp:730627 TIME_to_ulonglong: Assertion `0' failed in 5.1-micro on wrong argument to MAKETIME

correct the return value of Item_func_maketime::get_date()
This commit is contained in:
Sergei Golubchik
2011-03-07 16:27:49 +01:00
parent a8a757c6bb
commit 19a3c29d64
3 changed files with 9 additions and 1 deletions

View File

@@ -1427,3 +1427,6 @@ Warning 1292 Incorrect datetime value: '2010-40-50'
select subtime('0000-00-10 10:10:10', '30 10:00:00');
subtime('0000-00-10 10:10:10', '30 10:00:00')
NULL
select maketime(20,61,10)+0;
maketime(20,61,10)+0
NULL

View File

@@ -886,3 +886,8 @@ select truncate(date('2010-40-10'), 6);
select extract(month from '2010-40-50');
select subtime('0000-00-10 10:10:10', '30 10:00:00');
#
# lp:730627 TIME_to_ulonglong: Assertion `0' failed in 5.1-micro on wrong argument to MAKETIME
#
select maketime(20,61,10)+0;

View File

@@ -2582,7 +2582,7 @@ bool Item_func_maketime::get_date(MYSQL_TIME *ltime, uint fuzzy_date)
args[2]->null_value ||
minute < 0 || minute > 59 ||
second < 0 || second > 59)))
return 0;
return 1;
bzero(ltime, sizeof(*ltime));
ltime->time_type= MYSQL_TIMESTAMP_TIME;