From: Ludwig Nussel Date: Fri, 7 Sep 2018 07:47:25 +0000 (+0200) Subject: Add built in fallbacks for motd file X-Git-Tag: v2.33-rc1~28^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4866b7178614e7db0de15212e5846e1a5656211a;p=thirdparty%2Futil-linux.git Add built in fallbacks for motd file Use several locations for built in default for motd to allow for e.g. run time generated motd without having to modify config files. login.c already splits by colon. /usr/share/misc/motd - chould be shipped by distributions /run/motd - potentially run time created file with dynamic information /etc/motd - for the admin fill with local information Signed-off-by: Ludwig Nussel --- diff --git a/include/pathnames.h b/include/pathnames.h index abf0cdee98..3d5052e6f7 100644 --- a/include/pathnames.h +++ b/include/pathnames.h @@ -43,7 +43,7 @@ #ifndef _PATH_MAILDIR # define _PATH_MAILDIR "/var/spool/mail" #endif -#define _PATH_MOTDFILE "/etc/motd" +#define _PATH_MOTDFILE "/usr/share/misc/motd:/run/motd:/etc/motd" #ifndef _PATH_NOLOGIN # define _PATH_NOLOGIN "/etc/nologin" #endif