summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2008-07-14 16:12:27 +0100
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2008-07-14 16:12:27 +0100
commit6d77f23d062f047437dc8ce428d86a7ad9fa05b2 (patch)
tree184efa34ed15e420ed8ee45b3f81b862c61cf985
parent603d449610275db1e51816104630cce6d74ac9d4 (diff)
downloaddbus-python-6d77f23d062f047437dc8ce428d86a7ad9fa05b2.tar.gz
DBusPyServer: correctly unref the weakref object on errors
-rw-r--r--_dbus_bindings/server.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/_dbus_bindings/server.c b/_dbus_bindings/server.c
index 84d8a28..8b59125 100644
--- a/_dbus_bindings/server.c
+++ b/_dbus_bindings/server.c
@@ -309,7 +309,8 @@ err:
DBG("Failed to construct Server from DBusServer at %p", server);
Py_XDECREF(mainloop);
// Py_XDECREF(self);
-// Py_XDECREF(ref);
+ Py_XDECREF(ref);
+
if (server) {
Py_BEGIN_ALLOW_THREADS
dbus_server_disconnect(server);