]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
test: more data on geoip load failure.
authorNick Mathewson <nickm@torproject.org>
Fri, 23 Mar 2018 15:48:15 +0000 (11:48 -0400)
committerNick Mathewson <nickm@torproject.org>
Fri, 23 Mar 2018 15:48:15 +0000 (11:48 -0400)
src/test/test_geoip.c

index a5e11cc59f4242d4ba28b65eb983072e719dd071..be1376a3b16c2d932c573c365e77117548a94fe2 100644 (file)
@@ -404,7 +404,11 @@ test_geoip_load_file(void *arg)
             geoip_db_digest(AF_INET));
 
   const char FNAME[] = SRCDIR "/src/config/geoip";
-  tt_int_op(0, OP_EQ, geoip_load_file(AF_INET, FNAME));
+  int rv = geoip_load_file(AF_INET, FNAME);
+  if (rv != 0) {
+    TT_GRIPE(("Unable to load geoip from %s", escaped(FNAME)));
+  }
+  tt_int_op(0, OP_EQ, rv);
 
   /* Check that we loaded some countries; this will fail if there are ever
    * fewer than 50 countries in the world. */