Bug #34909: mysqldump returns a 0 status on error when using
--master-data No error code was returned by mysqldump if it detects that binary logging is not enabled on the server. Fixed by returning error code.
This commit is contained in:
parent
0596b1c6cd
commit
11cd97ed6b
@ -3285,6 +3285,7 @@ static int do_show_master_status(MYSQL *mysql_con)
|
|||||||
my_printf_error(0, "Error: Binlogging on server not active",
|
my_printf_error(0, "Error: Binlogging on server not active",
|
||||||
MYF(0));
|
MYF(0));
|
||||||
mysql_free_result(master);
|
mysql_free_result(master);
|
||||||
|
maybe_exit(EX_MYSQLERR);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
mysql_free_result(master);
|
mysql_free_result(master);
|
||||||
|
1
mysql-test/r/mysqldump-no-binlog.result
Normal file
1
mysql-test/r/mysqldump-no-binlog.result
Normal file
@ -0,0 +1 @@
|
|||||||
|
mysqldump: Error: Binlogging on server not active
|
1
mysql-test/t/mysqldump-no-binlog-master.opt
Normal file
1
mysql-test/t/mysqldump-no-binlog-master.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--skip-log-bin
|
6
mysql-test/t/mysqldump-no-binlog.test
Normal file
6
mysql-test/t/mysqldump-no-binlog.test
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
# Embedded server doesn't support external clients
|
||||||
|
--source include/not_embedded.inc
|
||||||
|
|
||||||
|
--replace_regex /MASTER_LOG_POS=[0-9]+/XX/
|
||||||
|
--error 2
|
||||||
|
--exec $MYSQL_DUMP --compact --master-data=2 test 2>&1
|
Loading…
x
Reference in New Issue
Block a user