From 1c57bf982ed1c2369d9c72c56b07ce6998252daf Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Wed, 6 Apr 2022 12:31:29 +0200 Subject: [PATCH] fix random bytes in ION_COLLECTION_NODE->data --- ionc/ion_collection.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ionc/ion_collection.c b/ionc/ion_collection.c index 567c5f7..9189f9c 100644 --- a/ionc/ion_collection.c +++ b/ionc/ion_collection.c @@ -308,10 +308,9 @@ ION_COLLECTION_NODE *_ion_collection_alloc_node_helper( ION_COLLECTION *collecti } // clean up the node before anyone uses it - node->_next = NULL; - node->_prev = NULL; + memset(node, 0, collection->_node_size); - return node; + return node; } ION_COLLECTION_NODE *_ion_collection_push_node_helper(ION_COLLECTION *collection)