summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/dbus-util.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2009-04-10 01:14:46 +0200
committerLennart Poettering <lennart@poettering.net>2009-04-10 01:14:46 +0200
commit669703daec2b9231ab80eefe3bccfca29cc3decb (patch)
tree05f71ee115ceca74a87c62b2e2444361d3c0d34f /src/pulsecore/dbus-util.c
parent9ba9883693ebe817532468c0974c8d5dccb4e006 (diff)
dbus: memory leak, free pending calls
Diffstat (limited to 'src/pulsecore/dbus-util.c')
-rw-r--r--src/pulsecore/dbus-util.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/pulsecore/dbus-util.c b/src/pulsecore/dbus-util.c
index 4e97046f..ece36def 100644
--- a/src/pulsecore/dbus-util.c
+++ b/src/pulsecore/dbus-util.c
@@ -380,8 +380,10 @@ pa_dbus_pending *pa_dbus_pending_new(
void pa_dbus_pending_free(pa_dbus_pending *p) {
pa_assert(p);
- if (p->pending)
- dbus_pending_call_cancel(p->pending); /* p->pending is freed by cancel() */
+ if (p->pending) {
+ dbus_pending_call_cancel(p->pending);
+ dbus_pending_call_unref(p->pending);
+ }
if (p->message)
dbus_message_unref(p->message);