From bb39bc9596a73f18b98fb6188b54661b357a4127 Mon Sep 17 00:00:00 2001 From: sin Date: Sun, 29 Sep 2013 19:26:08 +0100 Subject: [PATCH] Use /var/run/utmp for now Musl-libc seems to define that to /dev/null/utmp for a good reason. Use /var/run/utmp for now until we find a better way to deal with this. --- who.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/who.c b/who.c index 50b686a..e098c99 100644 --- a/who.c +++ b/who.c @@ -41,8 +41,8 @@ main(int argc, char **argv) if (argc > 0) usage(); - if (!(ufp = fopen(_PATH_UTMP, "r"))) - eprintf("who: '%s':", _PATH_UTMP); + if (!(ufp = fopen("/var/run/utmp", "r"))) + eprintf("who: '%s':", "/var/run/utmp"); while(fread(&usr, sizeof(usr), 1, ufp) == 1) { if (!*usr.ut_name || !*usr.ut_line ||