From 88bf1500095d7aaea9689a6d0367d6ff5c868292 Mon Sep 17 00:00:00 2001 From: Ed Schouten Date: Sat, 15 Sep 2012 20:27:57 +0200 Subject: Remove dubious code. The NO_UTMP definition is set on non-FreeBSD, non-OpenBSD, BSD-based systems. When looking at the commonly used BSD-based operating systems, they either use utmpx, or I can't think of a reason why the utmp code wouldn't work. If it turns out some obscure operating system breaks because of this change, we should replace this by something more accurate, such as an Autoconf check or an #ifdef specific to that operating system. Signed-off-by: Ed Schouten Signed-off-by: Alan Coopersmith --- sessreg.c | 4 ---- sessreg.h | 7 ------- 2 files changed, 11 deletions(-) diff --git a/sessreg.c b/sessreg.c index cc15869..43291eb 100644 --- a/sessreg.c +++ b/sessreg.c @@ -258,16 +258,12 @@ main (int argc, char **argv) wtmpx_file = WTMPX_FILE; #endif } -#ifndef NO_UTMP if (!uflag) { utmp_file = UTMP_FILE; #if defined(USE_UTMPX) && defined(HAVE_UTMPXNAME) utmpx_file = UTMPX_FILE; #endif } -#else - utmp_none = 1; -#endif #ifdef USE_LASTLOG if (!Lflag) llog_file = LLOG_FILE; diff --git a/sessreg.h b/sessreg.h index 0a0a209..71e93f1 100644 --- a/sessreg.h +++ b/sessreg.h @@ -75,13 +75,6 @@ # define USE_LASTLOG #endif -#ifdef CSRG_BASED -#if !defined(__FreeBSD__) && !defined(__OpenBSD__) -/* *BSD doesn't like a ':0' type entry in utmp */ -#define NO_UTMP -#endif -#endif - #ifndef WTMP_FILE # ifdef _PATH_WTMP # define WTMP_FILE _PATH_WTMP -- cgit v1.2.3