summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnders Kaseorg <andersk@mit.edu>2010-08-03 15:07:39 -0400
committerWilliam Jon McCann <jmccann@redhat.com>2010-08-03 15:07:39 -0400
commit7b9212fa6aff55420c58f2cacd0a941762920337 (patch)
tree8b9f03754f8ebdea582b2259ab6b38aaa1446c98
parent4f88228f31a63c026c424a92827f26ad7535275c (diff)
Fix a few memory leaks
https://bugs.freedesktop.org/show_bug.cgi?id=26227
-rw-r--r--src/ck-manager.c7
-rw-r--r--src/ck-session.c3
2 files changed, 9 insertions, 1 deletions
diff --git a/src/ck-manager.c b/src/ck-manager.c
index c36c0e0..cce4e0f 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
@@ -1925,6 +1931,7 @@ create_session_for_sender (CkManager *manager,
g_free (cookie);
g_free (ssid);
+ g_object_unref (leader);
return TRUE;
}
diff --git a/src/ck-session.c b/src/ck-session.c
index d434583..8a566bb 100644
--- a/src/ck-session.c
+++ b/src/ck-session.c
@@ -1105,9 +1105,10 @@ 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->x11_display);
+ g_free (session->priv->login_session_id);
g_free (session->priv->display_device);
g_free (session->priv->x11_display_device);
+ g_free (session->priv->x11_display);
g_free (session->priv->remote_host_name);
G_OBJECT_CLASS (ck_session_parent_class)->finalize (object);