You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What is the proper guideline for json_free() to prevent memory leaks? It seems to me from the recursive nature of json_free() that it is sufficient to call it for the topmost object, but still, in the README example you don't call it on any error, which leads me to believe the example contains a memory leak (of course the program exits but that's not the point).
Is it "call it on the value of the topmost unwrap but only if it was successful", or is it something else?
The text was updated successfully, but these errors were encountered:
What is the proper guideline for
json_free()
to prevent memory leaks? It seems to me from the recursive nature ofjson_free()
that it is sufficient to call it for the topmost object, but still, in the README example you don't call it on any error, which leads me to believe the example contains a memory leak (of course the program exits but that's not the point).Is it "call it on the value of the topmost unwrap but only if it was successful", or is it something else?
The text was updated successfully, but these errors were encountered: