diff options
author | Staale Smedseng <staale.smedseng@sun.com> | 2009-06-09 18:11:21 +0200 |
---|---|---|
committer | Staale Smedseng <staale.smedseng@sun.com> | 2009-06-09 18:11:21 +0200 |
commit | dae006c17fe4962c1f79060a10a1dc80dc07bf03 (patch) | |
tree | 193df6c7ac6afa01d015869845f23915230d1eaf /sql/item.cc | |
parent | e43d8e584d76aa646dd0a88cbb4b85b20fffe37c (diff) | |
download | mariadb-git-dae006c17fe4962c1f79060a10a1dc80dc07bf03.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 first patch, fixing a number
of the warnings, predominantly "suggest using parentheses
around && in ||", and empty for and while bodies.
Diffstat (limited to 'sql/item.cc')
-rw-r--r-- | sql/item.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/item.cc b/sql/item.cc index 7a81e48fcee..c20089694db 100644 --- a/sql/item.cc +++ b/sql/item.cc @@ -2587,7 +2587,7 @@ void Item_param::set_time(MYSQL_TIME *tm, timestamp_type time_type, if (value.time.year > 9999 || value.time.month > 12 || value.time.day > 31 || - time_type != MYSQL_TIMESTAMP_TIME && value.time.hour > 23 || + (time_type != MYSQL_TIMESTAMP_TIME && value.time.hour > 23) || value.time.minute > 59 || value.time.second > 59) { char buff[MAX_DATE_STRING_REP_LENGTH]; @@ -4728,8 +4728,8 @@ int Item::save_in_field(Field *field, bool no_conversions) { int error; if (result_type() == STRING_RESULT || - result_type() == REAL_RESULT && - field->result_type() == STRING_RESULT) + (result_type() == REAL_RESULT && + field->result_type() == STRING_RESULT)) { String *result; CHARSET_INFO *cs= collation.collation; |