Test suite: Regression fix - wait_until should not run command in sub-shell.
authorMartin Schwenke <martin@meltin.net>
Wed, 28 Oct 2009 02:02:18 +0000 (13:02 +1100)
committerMartin Schwenke <martin@meltin.net>
Wed, 28 Oct 2009 02:02:18 +0000 (13:02 +1100)
commit39642e745254d93d74dde907787503854fe6ca4a
tree2d31481544e7d670f1b295518620e18d96e064ae
parentf3e09f2cfd33e79e69fc8c84ce4781a31a7a0437
Test suite: Regression fix - wait_until should not run command in sub-shell.

Commit 25e82a8a667a54c6921ef076c63fdd738dd75d19 changed wait_until()
to protect the command it runs from "set -e" by running it in a
subshell.  This breaks uses where the command is expected to set
global variables.  For example, wait_until_get_src_socket lost the
value of $out from its call to get_src_socket().

The fix is to not be lazy and use a sub-shell!

Signed-off-by: Martin Schwenke <martin@meltin.net>
tests/scripts/ctdb_test_functions.bash