Commit 329761e8 authored by unknown's avatar unknown

Merge mysql.com:/home/dlenev/src/mysql-4.1-bg10040

into mysql.com:/home/dlenev/src/mysql-5.0-merges


sql/item_timefunc.cc:
  Auto merged
parents c1d6b29c 20cf8f82
Branches unavailable
Tags unavailable
No related merge requests found
...@@ -814,14 +814,14 @@ static bool calc_time_diff(TIME *l_time1, TIME *l_time2, int l_sign, ...@@ -814,14 +814,14 @@ static bool calc_time_diff(TIME *l_time1, TIME *l_time2, int l_sign,
We should check it before calc_time_diff call. We should check it before calc_time_diff call.
*/ */
if (l_time1->time_type == MYSQL_TIMESTAMP_TIME) // Time value if (l_time1->time_type == MYSQL_TIMESTAMP_TIME) // Time value
days= l_time1->day - l_sign*l_time2->day; days= (long)l_time1->day - l_sign * (long)l_time2->day;
else else
{ {
days= calc_daynr((uint) l_time1->year, days= calc_daynr((uint) l_time1->year,
(uint) l_time1->month, (uint) l_time1->month,
(uint) l_time1->day); (uint) l_time1->day);
if (l_time2->time_type == MYSQL_TIMESTAMP_TIME) if (l_time2->time_type == MYSQL_TIMESTAMP_TIME)
days-= l_sign*l_time2->day; days-= l_sign * (long)l_time2->day;
else else
days-= l_sign*calc_daynr((uint) l_time2->year, days-= l_sign*calc_daynr((uint) l_time2->year,
(uint) l_time2->month, (uint) l_time2->month,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment