summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Olav Hauglid <jon.hauglid@oracle.com>2016-02-08 11:28:20 +0100
committerJon Olav Hauglid <jon.hauglid@oracle.com>2016-02-08 13:08:50 +0100
commit1fb6d4e6bf3dd79fffb034ca4b014930b0304e1f (patch)
treec2399056151464e28af61369a83766eb72e7c99b
parent20c3063c314985141e2bfb10fc7bc858cdde0cdf (diff)
downloadmariadb-git-1fb6d4e6bf3dd79fffb034ca4b014930b0304e1f.tar.gz
Bug#22680706: 5.5 DOES NOT BUILD WITH GCC5
Fix the following two build warnings so that 5.5 can be compiled with GCC5. storage/innobase/dict/dict0crea.c:1143:21: error: logical not is only applied to the left hand side of comparison [-Werror=logical-not-parentheses] ut_a(!node->index == (err != DB_SUCCESS)); ^ storage/innobase/log/log0recv.c:1770:20: error: logical not is only applied to the left hand side of comparison [-Werror=logical-not-parentheses] ut_ad(!allow_ibuf == mutex_own(&log_sys->mutex)); ^
-rw-r--r--storage/innobase/dict/dict0crea.c4
-rw-r--r--storage/innobase/log/log0recv.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/storage/innobase/dict/dict0crea.c b/storage/innobase/dict/dict0crea.c
index ac8a1eac03c..e568dfa16c7 100644
--- a/storage/innobase/dict/dict0crea.c
+++ b/storage/innobase/dict/dict0crea.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1996, 2014, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1996, 2016, Oracle and/or its affiliates. All Rights Reserved.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -1140,7 +1140,7 @@ dict_create_index_step(
>= DICT_TF_FORMAT_ZIP);
node->index = dict_index_get_if_in_cache_low(index_id);
- ut_a(!node->index == (err != DB_SUCCESS));
+ ut_a((node->index == NULL) == (err != DB_SUCCESS));
if (err != DB_SUCCESS) {
diff --git a/storage/innobase/log/log0recv.c b/storage/innobase/log/log0recv.c
index ae3912da552..846d430c294 100644
--- a/storage/innobase/log/log0recv.c
+++ b/storage/innobase/log/log0recv.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1997, 2015, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1997, 2016, Oracle and/or its affiliates. All Rights Reserved.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -1767,7 +1767,7 @@ loop:
goto loop;
}
- ut_ad(!allow_ibuf == mutex_own(&log_sys->mutex));
+ ut_ad((!allow_ibuf) == mutex_own(&log_sys->mutex));
if (!allow_ibuf) {
recv_no_ibuf_operations = TRUE;