From dc95009e692071f56a194b6b1466c9a2b284feee Mon Sep 17 00:00:00 2001 From: Vincent Untz Date: Wed, 18 Apr 2012 08:57:11 +0200 Subject: [PATCH] daemon: Exclude users with no shell The NIS entry in /etc/passwd seems to be: +:::::: We obviously don't want a user with no shell to be visible, so use this more generic solution. --- src/daemon.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/daemon.c b/src/daemon.c index d186ab6..be98de7 100644 --- a/src/daemon.c +++ b/src/daemon.c @@ -163,8 +163,8 @@ daemon_local_user_is_excluded (Daemon *daemon, const gchar *username, const gcha char *basename, *nologin_basename, *false_basename; int ret; - if (shell == NULL) { - return FALSE; + if (shell == NULL || shell[0] == '\0') { + return TRUE; } ret = FALSE; -- 1.7.9.2