Commit 246a2afd authored by Lev Walkin's avatar Lev Walkin

proper free()

parent 35631487
......@@ -498,7 +498,9 @@ SET_OF_free(asn1_TYPE_descriptor_t *td, void *ptr, int contents_only) {
if(memb_ptr)
element->type->free_struct(element->type, memb_ptr, 0);
}
list->count = 0; /* Just in case */
list->count = 0; /* No meaningful elements left */
asn_set_empty(list); /* Remove (list->array) */
if(!contents_only) {
FREEMEM(ptr);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment