X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=etc%2Fafpd%2Fuam.c;h=a07787d8d061d0aad7a576b834ead48b549bf092;hb=9291bf0115fbf5520af9b0f21ce8f15fcde0eea1;hp=b00b83be875ae3326ee9c1e9fc4e14b27e993f78;hpb=9ef8c09f9f5cd6a9b4e3883154e01fa66ca483d1;p=netatalk.git diff --git a/etc/afpd/uam.c b/etc/afpd/uam.c index b00b83be..a07787d8 100644 --- a/etc/afpd/uam.c +++ b/etc/afpd/uam.c @@ -1,5 +1,5 @@ /* - * $Id: uam.c,v 1.15.2.2 2002-01-14 02:54:47 srittau Exp $ + * $Id: uam.c,v 1.15.2.3 2002-03-11 17:54:44 jmarcus Exp $ * * Copyright (c) 1999 Adrian Sun (asun@zoology.washington.edu) * All Rights Reserved. See COPYRIGHT. @@ -239,9 +239,16 @@ int uam_checkuser(const struct passwd *pwd) { const char *p; - if (!pwd || !pwd->pw_shell || (*pwd->pw_shell == '\0')) + if (!pwd) return -1; +#ifndef DISABLE_SHELLCHECK + if (!pwd->pw_shell || (*pwd->pw_shell == '\0')) { + syslog(LOG_INFO, "uam_checkuser: User %s does not have a shell", pwd->pw_name); + return -1; + } +#endif + while ((p = getusershell())) { if ( strcmp( p, pwd->pw_shell ) == 0 ) break;