summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/log_event.cc9
-rw-r--r--sql/log_event_old.cc9
2 files changed, 6 insertions, 12 deletions
diff --git a/sql/log_event.cc b/sql/log_event.cc
index c07bb573188..9c6de5bb42e 100644
--- a/sql/log_event.cc
+++ b/sql/log_event.cc
@@ -9029,14 +9029,11 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
BI image that is null and part of UNNI.
*/
bool null_found= FALSE;
-
- for (uint i=0, fieldnr= keyinfo->key_part[i].fieldnr - 1 ;
- (i < keyinfo->key_parts) && !null_found ;
- i++, fieldnr= keyinfo->key_part[i].fieldnr - 1)
+ for (uint i=0; i < keyinfo->key_parts && !null_found; i++)
{
+ uint fieldnr= keyinfo->key_part[i].fieldnr - 1;
Field **f= table->field+fieldnr;
- if ((*f)->is_null())
- null_found= TRUE;
+ null_found= (*f)->is_null();
}
if (!null_found)
diff --git a/sql/log_event_old.cc b/sql/log_event_old.cc
index 5f2d55d6477..8376eb6c584 100644
--- a/sql/log_event_old.cc
+++ b/sql/log_event_old.cc
@@ -2442,14 +2442,11 @@ int Old_rows_log_event::find_row(const Relay_log_info *rli)
BI image that is null and part of UNNI.
*/
bool null_found= FALSE;
-
- for (uint i=0, fieldnr= keyinfo->key_part[i].fieldnr - 1 ;
- (i < keyinfo->key_parts) && !null_found ;
- i++, fieldnr= keyinfo->key_part[i].fieldnr - 1)
+ for (uint i=0; i < keyinfo->key_parts && !null_found; i++)
{
+ uint fieldnr= keyinfo->key_part[i].fieldnr - 1;
Field **f= table->field+fieldnr;
- if ((*f)->is_null())
- null_found= TRUE;
+ null_found= (*f)->is_null();
}
if (!null_found)