Explorar o código

fix uninitialized memory reads from test_geoip_with_pt. Found with valgrind

Nick Mathewson %!s(int64=10) %!d(string=hai) anos
pai
achega
3fa296ce28
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      src/test/test.c

+ 2 - 0
src/test/test.c

@@ -1018,6 +1018,8 @@ test_geoip_with_pt(void)
   get_options_mutable()->BridgeRelay = 1;
   get_options_mutable()->BridgeRecordUsageByCountry = 1;
 
+  memset(&in6, 0, sizeof(in6));
+
   /* No clients seen yet. */
   s = geoip_get_transport_history();
   tor_assert(!s);