X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fcommon%2Fhashtable%2Fhashtable.c;h=8c26ebe15b63d3a71f2efd40398e2781e5ddbb59;hb=3a1aff7a271016fa0104e45492ca94e7e06b2492;hp=263df46839d37af58e2efe66770f5e1833c90f0f;hpb=d88aee689d5bd0067f362a323cb69c37717df59f;p=lttng-tools.git diff --git a/src/common/hashtable/hashtable.c b/src/common/hashtable/hashtable.c index 263df4683..8c26ebe15 100644 --- a/src/common/hashtable/hashtable.c +++ b/src/common/hashtable/hashtable.c @@ -105,6 +105,7 @@ struct lttng_ht *lttng_ht_new(unsigned long size, int type) break; default: ERR("Unknown lttng hashtable type %d", type); + lttng_ht_destroy(ht); goto error; } @@ -184,7 +185,7 @@ void lttng_ht_node_free_ulong(struct lttng_ht_node_ulong *node) /* * Free lttng ht node uint64_t. */ -void lttng_ht_node_free_u64(struct lttng_ht_node_ulong *node) +void lttng_ht_node_free_u64(struct lttng_ht_node_u64 *node) { assert(node); free(node);