Commit 24a19278 authored by unknown's avatar unknown

Manual fixes to merge of fix for Bug #6682 to 4.1.


sql/sql_class.h:
  update tmp_disable_binlog() and reenable_binlog() macros
mysql-test/r/insert_select.result:
  Handle results that differ from 4.0 to 4.1
parent 790974f3
...@@ -85,10 +85,10 @@ create table t1(a int); ...@@ -85,10 +85,10 @@ create table t1(a int);
insert into t1 values(1),(1); insert into t1 values(1),(1);
reset master; reset master;
create table t2(unique(a)) select a from t1; create table t2(unique(a)) select a from t1;
Duplicate entry '1' for key 1 ERROR 23000: Duplicate entry '1' for key 1
show binlog events; show binlog events;
Log_name Pos Event_type Server_id Orig_log_pos Info Log_name Pos Event_type Server_id Orig_log_pos Info
master-bin.001 4 Start 1 4 Server ver: VERSION, Binlog ver: 3 master-bin.000001 4 Start 1 4 Server ver: VERSION, Binlog ver: 3
drop table t1; drop table t1;
create table t1 (a int not null); create table t1 (a int not null);
create table t2 (a int not null); create table t2 (a int not null);
......
...@@ -1092,14 +1092,11 @@ class THD :public ilink, ...@@ -1092,14 +1092,11 @@ class THD :public ilink,
void end_statement(); void end_statement();
}; };
# define tmp_disable_binlog(A) \ #define tmp_disable_binlog(A) \
ulong save_options= (A)->options, save_master_access= (A)->master_access; \ ulong save_options= (A)->options; \
(A)->options&= ~OPTION_BIN_LOG; \ (A)->options&= ~OPTION_BIN_LOG;
(A)->master_access|= SUPER_ACL; /* unneeded in 4.1 */
#define reenable_binlog(A) (A)->options= save_options;
#define reenable_binlog(A) \
(A)->options= save_options; \
(A)->master_access= save_master_access;
/* Flags for the THD::system_thread (bitmap) variable */ /* Flags for the THD::system_thread (bitmap) variable */
#define SYSTEM_THREAD_DELAYED_INSERT 1 #define SYSTEM_THREAD_DELAYED_INSERT 1
......
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