Commit 7e894a1b authored by marko's avatar marko

ha_innobase::start_stmt(): Remove the check for

prebuilt->stored_select_lock_type being LOCK_X or LOCK_S.
This would cause false alarms with INSERT ... SELECT, which would use
LOCK_NONE in innodb_locks_unsafe_for_binlog mode.  (Bug #10746)
parent df49c4bf
...@@ -6177,25 +6177,11 @@ ha_innobase::start_stmt( ...@@ -6177,25 +6177,11 @@ ha_innobase::start_stmt(
1) ::store_lock(), 1) ::store_lock(),
2) ::external_lock(), 2) ::external_lock(),
3) ::init_table_handle_for_HANDLER(), and 3) ::init_table_handle_for_HANDLER(), and
4) :.transactional_table_lock(). */ 4) ::transactional_table_lock(). */
prebuilt->select_lock_type = prebuilt->select_lock_type =
prebuilt->stored_select_lock_type; prebuilt->stored_select_lock_type;
} }
if (prebuilt->stored_select_lock_type != LOCK_S
&& prebuilt->stored_select_lock_type != LOCK_X) {
sql_print_error(
"stored_select_lock_type is %lu inside "
"::start_stmt()!",
prebuilt->stored_select_lock_type);
/* Set the value to LOCK_X: this is just fault
tolerance, we do not know what the correct value
should be! */
prebuilt->select_lock_type = LOCK_X;
}
} }
trx->detailed_error[0] = '\0'; trx->detailed_error[0] = '\0';
......
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