Skip to content
Snippets Groups Projects
Commit d34c690e authored by Linus Nordberg's avatar Linus Nordberg
Browse files

Allocate vote_microdesc_hash_t using tor_malloc_zero().

In case the struct grows in the future. Shouldn't be too expensive.
parent 8ef395d6
No related branches found
No related tags found
No related merge requests found
......@@ -2798,7 +2798,7 @@ dirserv_generate_networkstatus_vote_obj(crypto_pk_t *private_key,
vote_microdesc_hash_t *h;
dirvote_format_microdesc_vote_line(buf, sizeof(buf), md,
cmr->low, cmr->high);
h = tor_malloc(sizeof(vote_microdesc_hash_t));
h = tor_malloc_zero(sizeof(vote_microdesc_hash_t));
h->microdesc_hash_line = tor_strdup(buf);
h->next = vrs->microdesc;
vrs->microdesc = h;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment