test_hs_control: initialize pointers to NULL

This is an attempt to fix CID 1486276, where coverity warns us that,
if the tests failed, we might free() an uninitialized pointer.
This commit is contained in:
Nick Mathewson 2021-07-12 14:59:29 -04:00
parent 9b2d179d95
commit 1d9de2948b

View File

@ -798,7 +798,7 @@ test_hs_control_add_onion_helper_add_service(void *arg)
hs_service_ht *global_map; hs_service_ht *global_map;
hs_port_config_t *portcfg; hs_port_config_t *portcfg;
smartlist_t *portcfgs; smartlist_t *portcfgs;
char *address_out_good, *address_out_bad; char *address_out_good = NULL, *address_out_bad = NULL;
hs_service_t *service_good = NULL; hs_service_t *service_good = NULL;
hs_service_t *service_bad = NULL; hs_service_t *service_bad = NULL;