summaryrefslogtreecommitdiff
path: root/sql/time.cc
diff options
context:
space:
mode:
authorStaale Smedseng <staale.smedseng@sun.com>2009-06-17 15:54:01 +0200
committerStaale Smedseng <staale.smedseng@sun.com>2009-06-17 15:54:01 +0200
commit30fccdaaaeaa8ed60537ec0e2d72bb8e1527f1a2 (patch)
treeb8fb3c1fb387986cd39d4dc291845cd51d2796e5 /sql/time.cc
parent9c1e2bbcf6d319fa91264713e4efde0cedf71f42 (diff)
downloadmariadb-git-30fccdaaaeaa8ed60537ec0e2d72bb8e1527f1a2.tar.gz
Bug #43414 Parenthesis (and other) warnings compiling MySQL
with gcc 4.3.2 Compiling MySQL with gcc 4.3.2 and later produces a number of warnings, many of which are new with the recent compiler versions. This bug will be resolved in more than one patch to limit the size of changesets. This is the second patch, fixing more of the warnings.
Diffstat (limited to 'sql/time.cc')
-rw-r--r--sql/time.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/time.cc b/sql/time.cc
index fb8a51fd0eb..b9cee5a986a 100644
--- a/sql/time.cc
+++ b/sql/time.cc
@@ -76,8 +76,8 @@ uint calc_week(MYSQL_TIME *l_time, uint week_behaviour, uint *year)
if (l_time->month == 1 && l_time->day <= 7-weekday)
{
if (!week_year &&
- (first_weekday && weekday != 0 ||
- !first_weekday && weekday >= 4))
+ ((first_weekday && weekday != 0) ||
+ (!first_weekday && weekday >= 4)))
return 0;
week_year= 1;
(*year)--;
@@ -94,8 +94,8 @@ uint calc_week(MYSQL_TIME *l_time, uint week_behaviour, uint *year)
if (week_year && days >= 52*7)
{
weekday= (weekday + calc_days_in_year(*year)) % 7;
- if (!first_weekday && weekday < 4 ||
- first_weekday && weekday == 0)
+ if ((!first_weekday && weekday < 4) ||
+ (first_weekday && weekday == 0))
{
(*year)++;
return 1;