[gdm] Don't call update_item_for_user on non-users in userlist
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm] Don't call update_item_for_user on non-users in userlist
- Date: Mon, 13 Sep 2010 14:23:11 +0000 (UTC)
commit 9027a2cb3db2bbf603540b97ee1398a90053a026
Author: Ray Strode <rstrode redhat com>
Date: Mon Sep 13 10:19:13 2010 -0400
Don't call update_item_for_user on non-users in userlist
Previously, get_user() it would fail right away and we
would avoid the call. Now get_user() returns a unloaded
stub object so we need to avoid calling get_user() in the
first place.
gui/simple-greeter/gdm-user-chooser-widget.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/gui/simple-greeter/gdm-user-chooser-widget.c b/gui/simple-greeter/gdm-user-chooser-widget.c
index 211b033..5aa2cfa 100644
--- a/gui/simple-greeter/gdm-user-chooser-widget.c
+++ b/gui/simple-greeter/gdm-user-chooser-widget.c
@@ -235,6 +235,14 @@ on_item_load (GdmChooserWidget *widget,
return;
}
+ if (strcmp (id, GDM_USER_CHOOSER_USER_OTHER) == 0) {
+ return;
+ }
+
+ if (strcmp (id, GDM_USER_CHOOSER_USER_GUEST) == 0) {
+ return;
+ }
+
user = gdm_user_manager_get_user (user_chooser->priv->manager, id);
if (user != NULL) {
update_item_for_user (user_chooser, user);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]