From 9969d7437fa6786782e6c780fbadd6561220ccfe Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Mon, 19 Apr 2021 11:26:23 +0000 Subject: Clean up the wtmp mess --- src/shutdown/s6-linux-init-hpr.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/shutdown/s6-linux-init-hpr.c') diff --git a/src/shutdown/s6-linux-init-hpr.c b/src/shutdown/s6-linux-init-hpr.c index 8ebe2d5..a874ac3 100644 --- a/src/shutdown/s6-linux-init-hpr.c +++ b/src/shutdown/s6-linux-init-hpr.c @@ -26,7 +26,11 @@ #endif #ifndef _PATH_WTMP -#define _PATH_WTMP "/dev/null/wtmp" +# ifdef WTMPX_FILE +# define _PATH_WTMP WTMPX_FILE +# else +# define _PATH_WTMP "/var/log/wtmp" +# endif #endif #define USAGE "s6-linux-init-hpr [ -h | -p | -r ] [ -n ] [ -d | -w ] [ -W ] [ -f ] [ -i ]" -- cgit v1.2.3