From: Christian Grothoff Date: Tue, 4 Jun 2019 21:30:14 +0000 (+0200) Subject: bloody off_t X-Git-Tag: v0.11.5~13 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=1e0b9f58484526d7551032dd1a50b0683d91cbd8;p=oweals%2Fgnunet.git bloody off_t --- diff --git a/src/gns/test_gns_cname_lookup.sh b/src/gns/test_gns_cname_lookup.sh index d97a4fe5e..d168e4acb 100755 --- a/src/gns/test_gns_cname_lookup.sh +++ b/src/gns/test_gns_cname_lookup.sh @@ -46,6 +46,9 @@ gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_ RES_CNAME=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t A -c test_gns_lookup.conf` RES_CNAME_RAW=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t CNAME -c test_gns_lookup.conf` RES_CNAME_DNS=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_DNS -t A -c test_gns_lookup.conf` +echo NOW +gnunet-gns --raw -u $TEST_DOMAIN_DNS -t A -c test_gns_lookup.conf +echo WON TESTEGOZONE=`gnunet-identity -c test_gns_lookup.conf -d | awk '{print $3}'` gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf @@ -78,6 +81,6 @@ then echo "PASS: IP resolution from DNS" exit 0 else - echo "FAIL: IP resolution from DNS, got $RES_IP, expected $TEST_IP_DNS." + echo "FAIL: IP resolution from DNS, got $RES_CNAME_DNS, expected $TEST_IP_DNS." exit 1 fi diff --git a/src/gns/test_gns_lookup.conf b/src/gns/test_gns_lookup.conf index 2b874f80d..2af52a0e2 100644 --- a/src/gns/test_gns_lookup.conf +++ b/src/gns/test_gns_lookup.conf @@ -6,6 +6,9 @@ DISABLE = YES [PATHS] GNUNET_TEST_HOME = $GNUNET_TMP/test-gnunet-gns-peer-1/ +[ARM] +OPTIONS = -l gnunet-%Y-%m-%d.log + [dht] START_ON_DEMAND = YES diff --git a/src/util/gnunet-service-resolver.c b/src/util/gnunet-service-resolver.c index 29ecf3e89..2cabe553b 100644 --- a/src/util/gnunet-service-resolver.c +++ b/src/util/gnunet-service-resolver.c @@ -344,7 +344,7 @@ lookup_dns_servers (char ***server_addrs) GNUNET_DISK_file_close (fh); return -1; } - if (bytes_read > (off_t) SIZE_MAX) + if (((unsigned long long) bytes_read) > (unsigned long long) SIZE_MAX) { GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "/etc/resolv.conf file too large to mmap. " @@ -1213,7 +1213,7 @@ load_etc_hosts (void) GNUNET_DISK_file_close (fh); return; } - if (bytes_read > (off_t) SIZE_MAX) + if (((unsigned long long) bytes_read) > (unsigned long long) SIZE_MAX) { GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "/etc/hosts file too large to mmap. "