summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@redhat.com>2012-06-15 18:42:43 +0200
committerTomas Bzatek <tbzatek@redhat.com>2012-07-31 11:59:37 +0200
commit24c5f03c4469951c2b631f5daadd8292c7564850 (patch)
tree038a4b7857b3830116e14e4f782be29b81f66e97
parent89a881c5bf8fcbaf027e276a302aefc11f8fca34 (diff)
downloadgvfs-24c5f03c4469951c2b631f5daadd8292c7564850.tar.gz
gdbus: Properly disconnect signal handlers
...not doing that leads to accessing freed memory
-rw-r--r--daemon/gvfsmonitor.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/daemon/gvfsmonitor.c b/daemon/gvfsmonitor.c
index b0508c52..358be8f4 100644
--- a/daemon/gvfsmonitor.c
+++ b/daemon/gvfsmonitor.c
@@ -145,6 +145,7 @@ unsubscribe (Subscriber *subscriber)
{
subscriber->monitor->priv->subscribers = g_list_remove (subscriber->monitor->priv->subscribers, subscriber);
+ g_signal_handlers_disconnect_by_data (subscriber->connection, subscriber);
g_object_unref (subscriber->connection);
g_free (subscriber->id);
g_free (subscriber->object_path);