From d08e244d011121f8ffd5c21437e0f11fe9545bbf Mon Sep 17 00:00:00 2001 From: Mathieu Duponchelle Date: Thu, 15 Feb 2018 23:32:08 +0100 Subject: Revert "Revert "Revert "Refactor boxed wrapper memory management strategy""" This reverts commit a506d5e3c64321c43a4ce7c2a72ca8d36e985999. --- gi/pygi-source.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'gi/pygi-source.c') diff --git a/gi/pygi-source.c b/gi/pygi-source.c index 5305260b..2ed38d37 100644 --- a/gi/pygi-source.c +++ b/gi/pygi-source.c @@ -241,10 +241,8 @@ pyg_source_new (void) source = (PyGRealSource*) g_source_new (&pyg_source_funcs, sizeof (PyGRealSource)); py_type = _pygi_type_import_by_name ("GLib", "Source"); - /* Full ownership transfer of the source, this will be free'd with g_boxed_free. */ - source->obj = _pygi_boxed_new ( (PyTypeObject *) py_type, source, - FALSE, /* copy_boxed */ - 0); /* slice_allocated */ + /* g_source_new uses malloc, not slices */ + source->obj = _pygi_boxed_new ( (PyTypeObject *) py_type, source, FALSE, 0); return source->obj; } -- cgit v1.2.1