diff options
author | Darren Tucker <dtucker@cvs.openbsd.org> | 2011-05-31 02:03:35 +0000 |
---|---|---|
committer | Darren Tucker <dtucker@cvs.openbsd.org> | 2011-05-31 02:03:35 +0000 |
commit | 5c2aadce78ba9ea16391dda78282ac4350a582e6 (patch) | |
tree | 76880e4ea3102d58cb965e69b93c218bc19dd777 /regress | |
parent | 23ba759e30a40b1be18cf80b603e2d68cd8b0228 (diff) |
work around startup and teardown races; caught by deraadt
Diffstat (limited to 'regress')
-rw-r--r-- | regress/usr.bin/ssh/dynamic-forward.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/regress/usr.bin/ssh/dynamic-forward.sh b/regress/usr.bin/ssh/dynamic-forward.sh index 4be6bd93f8f..3054b697411 100644 --- a/regress/usr.bin/ssh/dynamic-forward.sh +++ b/regress/usr.bin/ssh/dynamic-forward.sh @@ -1,4 +1,4 @@ -# $OpenBSD: dynamic-forward.sh,v 1.7 2011/05/31 02:01:58 dtucker Exp $ +# $OpenBSD: dynamic-forward.sh,v 1.8 2011/05/31 02:03:34 dtucker Exp $ # Placed in the Public Domain. tid="dynamic forwarding" @@ -19,7 +19,8 @@ start_sshd for p in 1 2; do trace "start dynamic forwarding, fork to background" - ${SSH} -$p -F $OBJ/ssh_config -f -D $FWDPORT -q somehost \ + ${SSH} -$p -F $OBJ/ssh_config -f -D $FWDPORT -q \ + -oExitOnForwardFailure=yes somehost \ exec sh -c \'"echo \$\$ > $OBJ/remote_pid; exec sleep 444"\' for s in 4 5; do @@ -39,6 +40,7 @@ for p in 1 2; do if [ $remote -gt 1 ]; then kill -HUP $remote fi + sleep 1 else fail "no pid file: $OBJ/remote_pid" fi |