diff options
author | Sergei Golubchik <serg@mariadb.org> | 2016-04-20 15:28:44 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2016-04-20 15:28:44 +0200 |
commit | 9e826bfa36a57f10540ca6ea649cb450add48cf4 (patch) | |
tree | 4c79d6549493429d3355424b94c570f4cd9da085 /sql/sql_table.cc | |
parent | 8f1f869f68581238b7718169fd50e9d7b6c7f0a3 (diff) | |
download | mariadb-git-9e826bfa36a57f10540ca6ea649cb450add48cf4.tar.gz |
trivial optimization
don't call write_bin_log() when binlog is known
to be disable
Diffstat (limited to 'sql/sql_table.cc')
-rw-r--r-- | sql/sql_table.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sql/sql_table.cc b/sql/sql_table.cc index 9d161ebc0de..024ca9b58e1 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -4880,8 +4880,10 @@ bool mysql_create_like_table(THD* thd, TABLE_LIST* table, TABLE_LIST* src_table, /* We have to write the query before we unlock the tables. */ - if (!thd->is_current_stmt_binlog_disabled() && - thd->is_current_stmt_binlog_format_row()) + if (thd->is_current_stmt_binlog_disabled()) + goto err; + + if (thd->is_current_stmt_binlog_format_row()) { /* Since temporary tables are not replicated under row-based |