mirror of
https://github.com/json-c/json-c.git
synced 2026-11-09 07:20:15 +08:00
Issue #923: Avoid stack recursion in json_object_put() so heavily nested object trees can be freed.
This commit is contained in:
1 parent
e50fb04154
commit
17328a6713
4 files changed
+168
-15
No files matched your search
@@ -47,7 +47,10 @@ struct json_object
|
||||
json_object_to_json_string_fn *_to_json_string;
|
||||
struct printbuf *_pb;
|
||||
json_object_delete_fn *_user_delete;
|
||||
void *_userdata;
|
||||
union {
|
||||
void *_userdata;
|
||||
void *_delete_parent; // Used during json_object_put
|
||||
};
|
||||
// Actually longer, always malloc'd as some more-specific type.
|
||||
// The rest of a struct json_object_${o_type} follows
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user