summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohan Dahlin <jdahlin@telia.com>2002-02-12 11:10:51 +0000
committerJohan Dahlin <zilch@src.gnome.org>2002-02-12 11:10:51 +0000
commit751ea167812fd730f6f79f55cfd02efe3a55aaf7 (patch)
tree8700cd8bb6f1ca996a0ba71e1874095aabe780c4
parenta8aff2c7e2887e7b6454b2fb80acac96ad362e59 (diff)
downloadpygobject-751ea167812fd730f6f79f55cfd02efe3a55aaf7.tar.gz
pygobject-751ea167812fd730f6f79f55cfd02efe3a55aaf7.tar.xz
pygobject-751ea167812fd730f6f79f55cfd02efe3a55aaf7.zip
Fix a leak
2002-02-12 Johan Dahlin <jdahlin@telia.com> * gobjectmodule.c (initgobject): Fix a leak * gtk/gtkmodule.c (init_gtk): Fix another one
-rw-r--r--gobject/gobjectmodule.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gobject/gobjectmodule.c b/gobject/gobjectmodule.c
index 5b62189..e13ccdb 100644
--- a/gobject/gobjectmodule.c
+++ b/gobject/gobjectmodule.c
@@ -1401,8 +1401,9 @@ initgobject(void)
/* for addon libraries ... */
PyDict_SetItemString(d, "_PyGObject_API",
- PyCObject_FromVoidPtr(&pygobject_api_functions,NULL));
-
+ o=PyCObject_FromVoidPtr(&pygobject_api_functions,NULL));
+ Py_DECREF(o);
+
/* some constants */
PyModule_AddIntConstant(m, "SIGNAL_RUN_FIRST", G_SIGNAL_RUN_FIRST);
PyModule_AddIntConstant(m, "SIGNAL_RUN_LAST", G_SIGNAL_RUN_LAST);