From 4a4b453a87da91a5051a1b7be9061861ec5c01a1 Mon Sep 17 00:00:00 2001 From: Alex Samorukov Date: Mon, 4 Jan 2021 19:35:09 +0100 Subject: Fix for the FEATURE_UTMP on the FreeBSD FreeBSD is not using and does not define _PATH_UTMPX. Tested with busybox applets depending on FEATURE_UTMP (e.g. who, users, etc) Signed-off-by: Alex Samorukov Signed-off-by: Denys Vlasenko --- include/libbb.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/include/libbb.h b/include/libbb.h index dad6fc6..cb63364 100644 --- a/include/libbb.h +++ b/include/libbb.h @@ -106,7 +106,11 @@ # define updwtmpx updwtmp # define _PATH_UTMPX _PATH_UTMP # else -# include +# if !defined(__FreeBSD__) +# include +# else +# define _PATH_UTMPX "/var/run/utx.active" +# endif # include # if defined _PATH_UTMP && !defined _PATH_UTMPX # define _PATH_UTMPX _PATH_UTMP -- cgit v1.1