summaryrefslogtreecommitdiff
path: root/tests/scripts/common.sh
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@redhat.com>2016-05-20 17:50:24 +0200
committerNikos Mavrogiannopoulos <nmav@redhat.com>2016-05-20 17:50:24 +0200
commitc46143f61e368509b355e6efd46352d016b8c6ab (patch)
treed8a917daa277cc3372653f8feb656173083014a5 /tests/scripts/common.sh
parent478cdc0742ece77d443de2e8642dcb1a059029c3 (diff)
downloadgnutls-c46143f61e368509b355e6efd46352d016b8c6ab.tar.gz
tests: use /bin/bash in tests which require common.sh
Diffstat (limited to 'tests/scripts/common.sh')
-rw-r--r--tests/scripts/common.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/scripts/common.sh b/tests/scripts/common.sh
index ec8c7c3c4f..9c9c3fb3aa 100644
--- a/tests/scripts/common.sh
+++ b/tests/scripts/common.sh
@@ -1,4 +1,5 @@
-# Copyright (C) 2011-2012 Free Software Foundation, Inc.
+# Copyright (C) 2011-2016 Free Software Foundation, Inc.
+# Copyright (C) 2015-2016 Red Hat, Inc.
#
# This file is part of GnuTLS.
#
@@ -18,6 +19,7 @@
# along with this file; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+# due to the use of $RANDOM, this script requires bash
GETPORT='rc=0;while test $rc = 0;do PORT="$(((($$<<15)|RANDOM) % 63001 + 2000))";
netstat -anl|grep "[\:\.]$PORT" >/dev/null 2>&1;