diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-09-26 08:52:43 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-09-26 08:52:43 +0000 |
commit | 02e344b557bfb88630df2c6d04f028c602f0f009 (patch) | |
tree | 384e7c7ca0671623d71b23171cdf3a01920e7a6c /src/gns/test_gns_cname_lookup.sh | |
parent | 626c2c8db33bfd00ed7d567a6e58182ca126df37 (diff) | |
download | gnunet-02e344b557bfb88630df2c6d04f028c602f0f009.tar.gz gnunet-02e344b557bfb88630df2c6d04f028c602f0f009.zip |
-check if timeout command exists before using it
Diffstat (limited to 'src/gns/test_gns_cname_lookup.sh')
-rwxr-xr-x | src/gns/test_gns_cname_lookup.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gns/test_gns_cname_lookup.sh b/src/gns/test_gns_cname_lookup.sh index d6b82a4b0..14e14c570 100755 --- a/src/gns/test_gns_cname_lookup.sh +++ b/src/gns/test_gns_cname_lookup.sh | |||
@@ -11,14 +11,15 @@ TEST_RECORD_CNAME_DNS="gnunet.org" | |||
11 | TEST_RECORD_NAME_SERVER="server" | 11 | TEST_RECORD_NAME_SERVER="server" |
12 | TEST_RECORD_NAME_PLUS="www" | 12 | TEST_RECORD_NAME_PLUS="www" |
13 | TEST_RECORD_NAME_DNS="www3" | 13 | TEST_RECORD_NAME_DNS="www3" |
14 | which timeout &> /dev/null && DO_TIMEOUT="timeout 5" | ||
14 | 15 | ||
15 | gnunet-arm -s -c test_gns_lookup.conf | 16 | gnunet-arm -s -c test_gns_lookup.conf |
16 | gnunet-identity -C testego -c test_gns_lookup.conf | 17 | gnunet-identity -C testego -c test_gns_lookup.conf |
17 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf | 18 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf |
18 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf | 19 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf |
19 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | 20 | gnunet-namestore -p -z testego -a -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf |
20 | RES_CNAME=$(timeout 5 gnunet-gns --raw -z testego -u www.gnu -t A -c test_gns_lookup.conf) | 21 | RES_CNAME=`$DO_TIMEOUT gnunet-gns --raw -z testego -u www.gnu -t A -c test_gns_lookup.conf` |
21 | RES_CNAME_DNS=$(timeout 5 gnunet-gns --raw -z testego -u www3.gnu -t A -c test_gns_lookup.conf) | 22 | RES_CNAME_DNS=`$DO_TIMEOUT gnunet-gns --raw -z testego -u www3.gnu -t A -c test_gns_lookup.conf` |
22 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf | 23 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf |
23 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf | 24 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf |
24 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | 25 | gnunet-namestore -p -z testego -d -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf |