diff options
author | Ted Gould <ted@gould.cx> | 2010-03-17 15:20:21 -0500 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2010-03-17 15:20:21 -0500 |
commit | 1d79b928f9df7e3185ba5846b06f3c7675ba4fea (patch) | |
tree | c5a23552dd4717caf05a8b1b4fb3922e02af9064 /src | |
parent | 8ab1eb8c5cb2e0c64681e473131b957818a74d82 (diff) | |
download | ayatana-indicator-session-1d79b928f9df7e3185ba5846b06f3c7675ba4fea.tar.gz ayatana-indicator-session-1d79b928f9df7e3185ba5846b06f3c7675ba4fea.tar.bz2 ayatana-indicator-session-1d79b928f9df7e3185ba5846b06f3c7675ba4fea.zip |
Some debugging an checking to ensure the menu item is not NULL
Diffstat (limited to 'src')
-rw-r--r-- | src/users-service-dbus.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/users-service-dbus.c b/src/users-service-dbus.c index d581887..86007c3 100644 --- a/src/users-service-dbus.c +++ b/src/users-service-dbus.c @@ -609,6 +609,7 @@ seat_proxy_session_added (DBusGProxy *seat_proxy, dbusmenu_menuitem_property_set_bool(priv->guest_item, USER_ITEM_PROP_LOGGED_IN, TRUE); } priv->guest_session_id = g_strdup(session_id); + g_debug("Found guest session: %s", priv->guest_session_id); return; } @@ -634,7 +635,10 @@ seat_proxy_session_removed (DBusGProxy *seat_proxy, username = g_hash_table_lookup (priv->sessions, session_id); if (!username) { if (g_strcmp0(session_id, priv->guest_session_id) == 0) { - dbusmenu_menuitem_property_set_bool(priv->guest_item, USER_ITEM_PROP_LOGGED_IN, FALSE); + g_debug("Removing guest session: %s", priv->guest_session_id); + if (priv->guest_item != NULL) { + dbusmenu_menuitem_property_set_bool(priv->guest_item, USER_ITEM_PROP_LOGGED_IN, FALSE); + } g_free(priv->guest_session_id); priv->guest_session_id = NULL; } |