[gupnp/wip/phako/reusable-service-action: 4/7] ServiceProxy: Do not leak cancellable in sync call
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gupnp/wip/phako/reusable-service-action: 4/7] ServiceProxy: Do not leak cancellable in sync call
- Date: Sat, 29 May 2021 00:23:05 +0000 (UTC)
commit 4fc97f8a8e87cd48bd7250b757c884904ade6a66
Author: Jens Georg <mail jensge org>
Date: Sat May 29 01:47:19 2021 +0200
ServiceProxy: Do not leak cancellable in sync call
libgupnp/gupnp-service-proxy.c | 5 +++++
1 file changed, 5 insertions(+)
---
diff --git a/libgupnp/gupnp-service-proxy.c b/libgupnp/gupnp-service-proxy.c
index 6a1729c..87f1932 100644
--- a/libgupnp/gupnp-service-proxy.c
+++ b/libgupnp/gupnp-service-proxy.c
@@ -2168,6 +2168,11 @@ gupnp_service_proxy_call_action (GUPnPServiceProxy *proxy,
session = gupnp_context_get_session (context);
soup_session_send_message (session, action->msg);
+ g_cancellable_disconnect (action->cancellable,
+ action->cancellable_connection_id);
+ action->cancellable_connection_id = 0;
+ g_clear_object (&action->cancellable);
+
/* If not allowed, try again */
if (action->msg->status_code == SOUP_STATUS_METHOD_NOT_ALLOWED) {
update_message_after_not_allowed (action->msg);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]