diff options
author | Simon Feltman <sfeltman@src.gnome.org> | 2013-10-05 17:00:54 -0700 |
---|---|---|
committer | Simon Feltman <sfeltman@src.gnome.org> | 2013-10-07 17:59:22 -0700 |
commit | 4623caa71c54958ab821db27a9eff2790acb3975 (patch) | |
tree | ef54e4bbebe5184f7abd9139335f5a0630caebec /gi/pygi-invoke.c | |
parent | 549f849ef8854352483657df3d7558688a4b0007 (diff) | |
download | pygobject-4623caa71c54958ab821db27a9eff2790acb3975.tar.gz |
Fix GValue array marshaling leaks and crash fallout
* Decrement references for results of PySequence_GetItem. There were a few
places we were not decrementing the Python reference, leaking the value.
* Add tracking of Python arguments with recursive marshaling cleanup. This
allows arrays of GValues which have been coerced from Python types to be
properly free'd (also fixes bug 703662).
* Use g_variant_ref for variant arguments marked as transfer everything.
This fixes double free's caused by the decrementing of PySequence_GetItem
results.
https://bugzilla.gnome.org/show_bug.cgi?id=693402
Diffstat (limited to 'gi/pygi-invoke.c')
-rw-r--r-- | gi/pygi-invoke.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gi/pygi-invoke.c b/gi/pygi-invoke.c index caa72bec..23036384 100644 --- a/gi/pygi-invoke.c +++ b/gi/pygi-invoke.c @@ -579,6 +579,7 @@ _invoke_marshal_out_args (PyGIInvokeState *state, PyGICallableCache *cache) if (to_py_cleanup != NULL) to_py_cleanup ( state, cache->return_cache, + NULL, &state->return_arg, FALSE); } |