#At file:///home/lsoares/Workspace/bzr/work/bugfixing/50780/mysql-5.1-bugteam/ based on revid:aelkin@stripped
3338 Luis Soares 2010-02-01
BUG#50780: 'show binary logs' debug assertion when binary
logging is disabled
The server would hit an assertion because of a DBUG violation.
There was a missing DBUG_RETURN and instead a plain return
was used.
This patch replaces the return with DBUG_RETURN.
added:
mysql-test/r/no_binlog.result
mysql-test/t/no_binlog.test
modified:
sql/sql_repl.cc
=== added file 'mysql-test/r/no_binlog.result'
--- a/mysql-test/r/no_binlog.result 1970-01-01 00:00:00 +0000
+++ b/mysql-test/r/no_binlog.result 2010-02-01 09:36:24 +0000
@@ -0,0 +1,2 @@
+SHOW BINARY LOGS;
+ERROR HY000: You are not using binary logging
=== added file 'mysql-test/t/no_binlog.test'
--- a/mysql-test/t/no_binlog.test 1970-01-01 00:00:00 +0000
+++ b/mysql-test/t/no_binlog.test 2010-02-01 09:36:24 +0000
@@ -0,0 +1,4 @@
+# BUG#50780: 'show binary logs' debug assertion when binary logging is disabled
+
+-- error 1381
+SHOW BINARY LOGS;
=== modified file 'sql/sql_repl.cc'
--- a/sql/sql_repl.cc 2010-01-24 07:03:23 +0000
+++ b/sql/sql_repl.cc 2010-02-01 09:36:24 +0000
@@ -1606,7 +1606,7 @@ bool show_binlogs(THD* thd)
if (!mysql_bin_log.is_open())
{
my_message(ER_NO_BINARY_LOGGING, ER(ER_NO_BINARY_LOGGING), MYF(0));
- return 1;
+ DBUG_RETURN(TRUE);
}
field_list.push_back(new Item_empty_string("Log_name", 255));
Attachment: [text/bzr-bundle] bzr/luis.soares@sun.com-20100201093624-q0cyk052kkdazgwt.bundle