]> ruderich.org/simon Gitweb - tlsproxy/tlsproxy.git/blobdiff - tests/tests-passthrough.sh
tests: Kill PIDs in stop_servers(), not process names.
[tlsproxy/tlsproxy.git] / tests / tests-passthrough.sh
index 5bac5bf8b784a90690f88dfc544f4fc43ff9c71d..9fb747ed645cb66c24bb2601e625fb1035727fc5 100755 (executable)
@@ -27,7 +27,7 @@ cleanup
 "$srcdir/../src/tlsproxy-setup" >/dev/null 2>/dev/null
 
 # Normal tests.
-../src/tlsproxy -d2 -u 4711 >/dev/null &
+tlsproxy -u 4711
 server --x509certfile "$srcdir/server.pem" \
        --x509keyfile "$srcdir/server-key.pem"
 sleep 1
@@ -72,7 +72,7 @@ test_no_invalid_certificate
 
 # Stop server and try a "MITM" with a bad certificate.
 echo
-pkill -n gnutls-serv
+kill $pid_server || echo 'failed to kill gnutls-serv'
 server --x509certfile "$srcdir/server-bad.pem" \
        --x509keyfile "$srcdir/server-key.pem"
 sleep 1