1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

BUG#11765650 Follow-up patch for Valgrind failures on PB2.

This commit is contained in:
Rohit Kalhans
2012-04-03 00:35:43 +05:30
parent fe9352454f
commit 6b6b8f0582

View File

@ -5711,6 +5711,8 @@ bool lock_tables(THD *thd, TABLE_LIST *tables, uint count,
if (!query_table->placeholder() &&
query_table->lock_type >= TL_WRITE_ALLOW_WRITE &&
unique_keys > 1 && thd->lex->sql_command == SQLCOM_INSERT &&
/* Duplicate key update is not supported by INSERT DELAYED */
thd->command != COM_DELAYED_INSERT &&
thd->lex->duplicates == DUP_UPDATE)
thd->lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_INSERT_TWO_KEYS);
}