From d86271732828117d32270e9f7b3d128d77e9fa57 Mon Sep 17 00:00:00 2001 From: Sören Tempel Date: Mon, 24 Aug 2015 22:16:48 +0200 Subject: 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 Signed-off-by: Denys Vlasenko --- loginutils/login.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/loginutils/login.c b/loginutils/login.c index b9d9103..1700cfc 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); -- cgit v1.1