From 9c788d0c7ea08b3181b5b9acc5014bf47cdd9eeb Mon Sep 17 00:00:00 2001 From: Pauli Virtanen Date: Sun, 30 Apr 2023 18:38:20 +0300 Subject: [PATCH] bluez5: unref pending calls after cancel Cancel doesn't decrease refcount, so needs unref too. --- spa/plugins/bluez5/bluez5-dbus.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spa/plugins/bluez5/bluez5-dbus.c b/spa/plugins/bluez5/bluez5-dbus.c index 5e6fe9132..0e71d69a1 100644 --- a/spa/plugins/bluez5/bluez5-dbus.c +++ b/spa/plugins/bluez5/bluez5-dbus.c @@ -2632,6 +2632,7 @@ void spa_bt_transport_free(struct spa_bt_transport *transport) if (transport->acquire_call) { dbus_pending_call_cancel(transport->acquire_call); + dbus_pending_call_unref(transport->acquire_call); transport->acquire_call = NULL; } @@ -3551,6 +3552,7 @@ static int do_transport_release(struct spa_bt_transport *transport) if (transport->acquire_call) { dbus_pending_call_cancel(transport->acquire_call); + dbus_pending_call_unref(transport->acquire_call); transport->acquire_call = NULL; }