diff options
author | Bernhard Reutner-Fischer | 2006-05-26 14:41:40 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer | 2006-05-26 14:41:40 +0000 |
commit | 781e42d66c120183e4dea1058dc539bdc4c53651 (patch) | |
tree | b139320b4b1275de767168b811ca45d1523f0573 /libbb | |
parent | b180e5a76678f697b2a368e2ef607d299d06a3ae (diff) | |
download | busybox-781e42d66c120183e4dea1058dc539bdc4c53651.zip busybox-781e42d66c120183e4dea1058dc539bdc4c53651.tar.gz |
- introduce and use bb_path_wtmp_file for portability (saves 11 Bytes).
- fix last.c to also look at the double-underscore UT_ defines.
Diffstat (limited to 'libbb')
-rw-r--r-- | libbb/messages.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libbb/messages.c b/libbb/messages.c index ab4c5d4..89ac94e 100644 --- a/libbb/messages.c +++ b/libbb/messages.c @@ -93,6 +93,20 @@ const char * const bb_default_login_shell = LIBBB_DEFAULT_LOGIN_SHELL; const char * const bb_dev_null = "/dev/null"; #endif +#ifdef L_bb_path_wtmp_file +#include <utmp.h> +/* This is usually something like "/var/adm/wtmp" or "/var/log/wtmp" */ +const char * const bb_path_wtmp_file = +#if defined _PATH_WTMP +_PATH_WTMP; +#elif defined WTMP_FILE +WTMP_FILE; +#else +# error unknown path to wtmp file +#endif +#endif + + #ifdef L_bb_common_bufsiz1 char bb_common_bufsiz1[BUFSIZ+1]; #endif |