Commit 03db6b0d authored by Manuel Pégourié-Gonnard's avatar Manuel Pégourié-Gonnard
Browse files

Cosmetics in test scripts

Some versions of "which" print on stderr.
parent 4fd0b256
......@@ -25,7 +25,7 @@ SRVMEM=0
: ${GNUTLS_SERV:=gnutls-serv}
# do we have a recent enough GnuTLS?
if ( which $GNUTLS_CLI && which $GNUTLS_SERV ) >/dev/null; then
if ( which $GNUTLS_CLI && which $GNUTLS_SERV ) >/dev/null 2>&1; then
G_VER="$( $GNUTLS_CLI --version | head -n1 )"
if echo "$G_VER" | grep '@VERSION@' > /dev/null; then # git version
PEER_GNUTLS=" GnuTLS"
......
......@@ -107,7 +107,7 @@ requires_openssl_with_fallback_scsv() {
# skip next test if GnuTLS isn't available
requires_gnutls() {
if [ -z "${GNUTLS_AVAILABLE:-}" ]; then
if ( which "$GNUTLS_CLI" && which "$GNUTLS_SERV" ) >/dev/null; then
if ( which "$GNUTLS_CLI" && which "$GNUTLS_SERV" ) >/dev/null 2>&1; then
GNUTLS_AVAILABLE="YES"
else
GNUTLS_AVAILABLE="NO"
......@@ -229,7 +229,7 @@ has_mem_err() {
# wait for server to start: two versions depending on lsof availability
wait_server_start() {
if which lsof >/dev/null; then
if which lsof >/dev/null 2>&1; then
# make sure we don't loop forever
( sleep "$DOG_DELAY"; echo "SERVERSTART TIMEOUT"; kill $MAIN_PID ) &
DOG_PID=$!
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment