diff options
author | Darren Tucker <dtucker@zip.com.au> | 2005-11-12 21:30:07 +1100 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2005-11-12 21:30:07 +1100 |
commit | cb6ecdea6c56c21da4b9ba0612ce4a035ffe6417 (patch) | |
tree | fd9497c89d5e3b51030c64e3b0e059248c319775 /regress/reconfigure.sh | |
parent | 5bfe1687dd85151649584aaaaf9bd85b67c9b61a (diff) |
- (dtucker) [regress/reconfigure.sh] Fix potential race in the reconfigure
test: if sshd takes too long to reconfigure the subsequent connection will
fail. Zap pidfile before HUPing sshd which will rewrite it when it's ready.
Diffstat (limited to 'regress/reconfigure.sh')
-rw-r--r-- | regress/reconfigure.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/regress/reconfigure.sh b/regress/reconfigure.sh index ba6dbc6f5..1daf29f9a 100644 --- a/regress/reconfigure.sh +++ b/regress/reconfigure.sh | |||
@@ -15,8 +15,9 @@ esac | |||
15 | 15 | ||
16 | start_sshd | 16 | start_sshd |
17 | 17 | ||
18 | $SUDO kill -HUP `cat $PIDFILE` | 18 | PID=`cat $PIDFILE` |
19 | sleep 1 | 19 | rm -f $PIDFILE |
20 | $SUDO kill -HUP $PID | ||
20 | 21 | ||
21 | trace "wait for sshd to restart" | 22 | trace "wait for sshd to restart" |
22 | i=0; | 23 | i=0; |