From c09b26733ccfec7754ba2df37dc660ad3268afbc Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Mon, 2 Aug 2010 16:29:39 -0400 Subject: [PATCH] on_seat_session_added_full and friends: Don’t leak ssid MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Anders Kaseorg --- src/ck-manager.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/ck-manager.c b/src/ck-manager.c index 1dfc789..5770219 100644 --- a/src/ck-manager.c +++ b/src/ck-manager.c @@ -1251,6 +1251,8 @@ on_seat_active_session_changed_full (CkSeat *seat, ck_seat_run_programs (seat, old_session, session, "seat_active_session_changed"); log_seat_active_session_changed_event (manager, seat, ssid); + + g_free (ssid); } static void @@ -1266,6 +1268,8 @@ on_seat_session_added_full (CkSeat *seat, ck_session_run_programs (session, "session_added"); log_seat_session_added_event (manager, seat, ssid); + + g_free (ssid); } static void @@ -1281,6 +1285,8 @@ on_seat_session_removed_full (CkSeat *seat, ck_session_run_programs (session, "session_removed"); log_seat_session_removed_event (manager, seat, ssid); + + g_free (ssid); } static void -- 1.7.2 From 1968d19bb3c3d6f848da02b458e22a1a72e0a858 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Mon, 2 Aug 2010 17:46:40 -0400 Subject: [PATCH] create_session_for_sender: Don’t leak a reference to the new session leader MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Anders Kaseorg --- src/ck-manager.c | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/src/ck-manager.c b/src/ck-manager.c index 5770219..96399cc 100644 --- a/src/ck-manager.c +++ b/src/ck-manager.c @@ -1693,6 +1693,8 @@ collect_parameters_cb (CkSessionLeader *leader, leader, parameters, context); + + g_object_unref (leader); } static void @@ -1713,6 +1715,8 @@ generate_session_for_leader (CkManager *manager, "Unable to get information about the calling process"); dbus_g_method_return_error (context, error); g_error_free (error); + + g_object_unref (leader); } } @@ -1764,9 +1768,10 @@ create_session_for_sender (CkManager *manager, g_object_ref (leader)); generate_session_for_leader (manager, - leader, + g_object_ref (leader), context); + g_object_unref (leader); g_free (cookie); g_free (ssid); -- 1.7.2 From d3dea22a0fd9d97840dc99294be214a9f8be3d01 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Mon, 2 Aug 2010 17:47:15 -0400 Subject: [PATCH] ck_session_finalize: Don’t leak login_session_id MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Anders Kaseorg --- src/ck-session.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/ck-session.c b/src/ck-session.c index d434583..bf6556e 100644 --- a/src/ck-session.c +++ b/src/ck-session.c @@ -1105,6 +1105,7 @@ ck_session_finalize (GObject *object) g_free (session->priv->cookie); g_free (session->priv->seat_id); g_free (session->priv->session_type); + g_free (session->priv->login_session_id); g_free (session->priv->x11_display); g_free (session->priv->display_device); g_free (session->priv->x11_display_device); -- 1.7.2