summaryrefslogtreecommitdiff
path: root/sql/item_timefunc.cc
diff options
context:
space:
mode:
authorunknown <ramil/ram@myoffice.izhnet.ru>2006-11-16 18:13:27 +0400
committerunknown <ramil/ram@myoffice.izhnet.ru>2006-11-16 18:13:27 +0400
commit902ce6fc8b73bf0e8eb9eae881ddda21cb1092c8 (patch)
tree738dd16e545b20e8a993672158c6e4d4f1cc724d /sql/item_timefunc.cc
parent153421fb069ca51a225e55f370720d657dac8cfd (diff)
parent8639c18f4dd9501357bc1db7b0fae5de5101c8e3 (diff)
downloadmariadb-git-902ce6fc8b73bf0e8eb9eae881ddda21cb1092c8.tar.gz
Merge mysql.com:/usr/home/ram/work/mysql-5.0-maint
into mysql.com:/usr/home/ram/work/mysql-5.1-maint mysql-test/r/sp.result: Auto merged mysql-test/t/sp.test: Auto merged sql/item_func.cc: Auto merged sql/item_timefunc.cc: Auto merged sql/sql_parse.cc: Auto merged
Diffstat (limited to 'sql/item_timefunc.cc')
-rw-r--r--sql/item_timefunc.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/sql/item_timefunc.cc b/sql/item_timefunc.cc
index fe5de9fd665..8c9e32a3ce9 100644
--- a/sql/item_timefunc.cc
+++ b/sql/item_timefunc.cc
@@ -3246,7 +3246,11 @@ bool Item_func_last_day::get_date(TIME *ltime, uint fuzzy_date)
{
if (get_arg0_date(ltime, fuzzy_date & ~TIME_FUZZY_DATE) ||
(ltime->month == 0))
+ {
+ null_value= 1;
return 1;
+ }
+ null_value= 0;
uint month_idx= ltime->month-1;
ltime->day= days_in_month[month_idx];
if ( month_idx == 1 && calc_days_in_year(ltime->year) == 366)