diff options
author | Sören Tempel <soeren@soeren-tempel.net> | 2015-08-24 22:16:48 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2015-08-24 22:16:48 +0200 |
commit | d86271732828117d32270e9f7b3d128d77e9fa57 (patch) | |
tree | aabe6340b3a3c0e0accbafe0c78e2b0018950047 /loginutils | |
parent | 864d1b7a1506002ef5804305b31e0fd7197c1ea4 (diff) |
login: don't print motd if .hushlogin exists in users home
function old new delta
login_main 978 996 +18
Signed-off-by: Sören Tempel <soeren@soeren-tempel.net>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'loginutils')
-rw-r--r-- | loginutils/login.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/loginutils/login.c b/loginutils/login.c index b9d910331..1700cfcb5 100644 --- a/loginutils/login.c +++ b/loginutils/login.c @@ -489,7 +489,8 @@ int login_main(int argc UNUSED_PARAM, char **argv) } #endif - motd(); + if (access(".hushlogin", F_OK) != 0) + motd(); if (pw->pw_uid == 0) syslog(LOG_INFO, "root login%s", fromhost); |