From 04498c2a4f1eb9e3f33ec4f66fe0cd85c41380a4 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 6 Jan 2005 22:30:23 -0600 Subject: [PATCH 1/3] Bootstrap: Made the default --mail address to be . Build-tools/Bootstrap: Made the default --mail address to be . --- Build-tools/Bootstrap | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Build-tools/Bootstrap b/Build-tools/Bootstrap index 10211dbb59c..10ebc5c2dd1 100755 --- a/Build-tools/Bootstrap +++ b/Build-tools/Bootstrap @@ -38,7 +38,7 @@ $opt_dry_run= undef; $opt_export_only= undef; $opt_help= $opt_verbose= 0; $opt_log= undef; -$opt_mail= ""; +$opt_mail= "build\@mysql.com"; $opt_pull= undef; $opt_revision= undef; $opt_suffix= ""; @@ -431,6 +431,7 @@ Options: include a log file snippet, if logging is enabled) Note that the \@-Sign needs to be quoted! Example: --mail=user\\\@domain.com + Default: build\@mysql.com -q, --quiet Be quiet -p, --pull Update the source BK trees before building -r, --revision= Export the tree as of revision From d8d9f79e09dfe822586742a62928ce37c44aaa90 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 10 Jan 2005 13:52:32 +0100 Subject: [PATCH 2/3] Fix for BUG#7658 "optimize crashes slave thread (1 in 1000)]": mysql_admin_table() attempted to write to a vio which was 0. I could have fixed mysql_admin_table() but fixing my_net_write() looked more future-proof. sql/net_serv.cc: If no VIO, no write. --- sql/net_serv.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sql/net_serv.cc b/sql/net_serv.cc index e5cb4d1e815..cad1f041005 100644 --- a/sql/net_serv.cc +++ b/sql/net_serv.cc @@ -227,6 +227,8 @@ int my_net_write(NET *net,const char *packet,ulong len) { uchar buff[NET_HEADER_SIZE]; + if (unlikely(!net->vio)) // nowhere to write + return 0; /* Big packets are handled by splitting them in packets of MAX_PACKET_LENGTH length. The last packet is always a packet that is < MAX_PACKET_LENGTH. From 87e1a296abe9e2962e7047b4f92e57425a858f70 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 10 Jan 2005 15:13:33 +0100 Subject: [PATCH 3/3] A test for the BUG#7658 just fixed in 4.0 (could not put it into 4.0 as in 4.0 we don't replicate OPTIMIZE TABLE). --- mysql-test/r/rpl_many_optimize.result | 9 +++++++++ mysql-test/t/rpl_many_optimize.test | 20 ++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 mysql-test/r/rpl_many_optimize.result create mode 100644 mysql-test/t/rpl_many_optimize.test diff --git a/mysql-test/r/rpl_many_optimize.result b/mysql-test/r/rpl_many_optimize.result new file mode 100644 index 00000000000..b2148892591 --- /dev/null +++ b/mysql-test/r/rpl_many_optimize.result @@ -0,0 +1,9 @@ +stop slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +reset master; +reset slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +start slave; +create table t1 (a int not null auto_increment primary key, b int, key(b)); +INSERT INTO t1 (a) VALUES (1),(2); +drop table t1; diff --git a/mysql-test/t/rpl_many_optimize.test b/mysql-test/t/rpl_many_optimize.test new file mode 100644 index 00000000000..525e23abe15 --- /dev/null +++ b/mysql-test/t/rpl_many_optimize.test @@ -0,0 +1,20 @@ +# Test for BUG#7658 "optimize crashes slave thread (1 in 1000)]" + +source include/master-slave.inc; + +create table t1 (a int not null auto_increment primary key, b int, key(b)); +INSERT INTO t1 (a) VALUES (1),(2); +# Now many OPTIMIZE to test if we crash (BUG#7658) +let $1=300; +disable_query_log; +disable_result_log; +while ($1) +{ + eval OPTIMIZE TABLE t1; + dec $1; +} +enable_result_log; +enable_query_log; +drop table t1; +# Bug was that slave segfaulted after ~ a hundred of OPTIMIZE (or ANALYZE) +sync_slave_with_master;