aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAndreas Schneider <asn@cryptomilk.org>2016-01-18 12:01:56 +0100
committerAndreas Schneider <asn@cryptomilk.org>2016-01-18 12:01:56 +0100
commita3557b81de2b37b021bc048a569045094866c461 (patch)
tree294ae304ae48bddd335e125b2f2d4c9a546a16b7 /tests
parent485d78d7684a974d616dfee2a394d5ede6571d72 (diff)
downloadlibssh-a3557b81de2b37b021bc048a569045094866c461.tar.gz
libssh-a3557b81de2b37b021bc048a569045094866c461.tar.xz
libssh-a3557b81de2b37b021bc048a569045094866c461.zip
tests: Wait for sshd to start before connecting
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/torture.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/torture.c b/tests/torture.c
index 067dc5d9..6a744bf7 100644
--- a/tests/torture.c
+++ b/tests/torture.c
@@ -971,6 +971,9 @@ void torture_setup_sshd_server(void **state)
rc = system(sshd_start_cmd);
assert_return_code(rc, errno);
+ /* Give the process some time to start */
+ usleep(300);
+
setenv("SOCKET_WRAPPER_DEFAULT_IFACE", "21", 1);
unsetenv("UID_WRAPPER_ROOT");
unsetenv("PAM_WRAPPER");