From 00a09b9d6a4a366b6e6dbd15e1e1e273bb0dc9c1 Mon Sep 17 00:00:00 2001 From: Mark Eichin Date: Fri, 29 Sep 1995 03:15:32 +0000 Subject: [PATCH] (gets it to actually build on sunos, and provides a fair guess for other systems) * update_utmp.c: ultimately fall back to /etc/utmp for UTMP_FILE, if it is still missing after all previous efforts. * update_wtmp.c: /usr/adm/wtmp for WTMP_FILE likewise. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6882 dc483132-0cff-0310-8789-dd5450dbe970 --- src/util/pty/ChangeLog | 6 ++++++ src/util/pty/update_utmp.c | 5 +++++ src/util/pty/update_wtmp.c | 5 +++++ 3 files changed, 16 insertions(+) diff --git a/src/util/pty/ChangeLog b/src/util/pty/ChangeLog index dba1b0e60..db9fc635e 100644 --- a/src/util/pty/ChangeLog +++ b/src/util/pty/ChangeLog @@ -3,6 +3,12 @@ Mon Sep 25 16:42:36 1995 Theodore Y. Ts'o * Makefile.in: Removed "foo:: foo-$(WHAT)" lines from the Makefile. +Thu Sep 7 19:13:05 1995 Mark Eichin + + * update_utmp.c: ultimately fall back to /etc/utmp for UTMP_FILE, + if it is still missing after all previous efforts. + * update_wtmp.c: /usr/adm/wtmp for WTMP_FILE likewise. + Thu Aug 24 18:40:48 1995 Theodore Y. Ts'o * .Sanitize: Update file list diff --git a/src/util/pty/update_utmp.c b/src/util/pty/update_utmp.c index f43ab3940..758d40a16 100644 --- a/src/util/pty/update_utmp.c +++ b/src/util/pty/update_utmp.c @@ -25,6 +25,11 @@ #define UTMP_FILE _PATH_UTMP #endif +/* if it is *still* missing, assume SunOS */ +#ifndef UTMP_FILE +#define UTMP_FILE "/etc/utmp" +#endif + long pty_update_utmp (process_type, pid, username, line, host) int process_type; int pid; diff --git a/src/util/pty/update_wtmp.c b/src/util/pty/update_wtmp.c index c71aba311..7bad3b635 100644 --- a/src/util/pty/update_wtmp.c +++ b/src/util/pty/update_wtmp.c @@ -25,6 +25,11 @@ #define WTMP_FILE _PATH_WTMP #endif +/* if it is *still* missing, assume SunOS */ +#ifndef WTMP_FILE +#define WTMP_FILE "/usr/adm/wtmp" +#endif + long ptyint_update_wtmp (ent) struct utmp *ent; { -- 2.26.2