[Commits] 8253b25: Fix that MTR leaks restart: options to following test

Kristian Nielsen knielsen at knielsen-hq.org
Fri Mar 24 12:52:53 EET 2017

revision-id: 8253b258b6721f226adfb5ef7448b42963ce755f (mariadb-10.1.21-9-g8253b25)
parent(s): 7525e1940ccec3ea3a19d07a8107d2e85fc3a0a1
author: Kristian Nielsen
committer: Kristian Nielsen
timestamp: 2017-03-24 11:51:23 +0100

Fix that MTR leaks restart: options to following test

This was found during MDEV-12179 development, but unrelated so put in its
own commit.

The "restart: --extra-option" facility in expect file for server restart
sets extra options for the restarted mysqld. These options were incorrectly
not cleared when starting a new test case, so the server was restarted with
whatever extra options were left by the previous testcase, causing random
failures depending on order of running tests.

 mysql-test/mysql-test-run.pl | 1 +
 1 file changed, 1 insertion(+)

diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
index 2485b94..e6feb7a 100755
--- a/mysql-test/mysql-test-run.pl
+++ b/mysql-test/mysql-test-run.pl
@@ -5239,6 +5239,7 @@ sub server_need_restart {
     if (!My::Options::same($started_opts, $extra_opts) ||
         exists $server->{'restart_opts'})
+      delete $server->{'restart_opts'};
       my $use_dynamic_option_switch= 0;
       if (!$use_dynamic_option_switch)

More information about the commits mailing list