From: Tom Yu Date: Wed, 9 Aug 1995 02:25:21 +0000 (+0000) Subject: * update_utmp.c (UTMP_FILE): _PATH_UTMP under NetBSD, not X-Git-Tag: krb5-1.0-beta6~1350 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=f6c08ffd8d8020510cbdb325a4f0a4ea79b7bb16;p=krb5.git * update_utmp.c (UTMP_FILE): _PATH_UTMP under NetBSD, not _UTMP_PATH; also fix typo (missing '&' on reference to ent) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6476 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/util/pty/ChangeLog b/src/util/pty/ChangeLog index 56d5e36ba..30d40969f 100644 --- a/src/util/pty/ChangeLog +++ b/src/util/pty/ChangeLog @@ -1,3 +1,9 @@ +Tue Aug 8 22:20:33 1995 Tom Yu + + * update_utmp.c (UTMP_FILE): _PATH_UTMP under NetBSD, not + _UTMP_PATH; also fix typo (missing '&' on reference to + ent) + Tue Aug 8 20:47:01 1995 Tom Yu * update_utmp.c (pty_update_utmp): change #ifdef NO_UT_PID to diff --git a/src/util/pty/update_utmp.c b/src/util/pty/update_utmp.c index 9e40ec7e3..f43ab3940 100644 --- a/src/util/pty/update_utmp.c +++ b/src/util/pty/update_utmp.c @@ -21,8 +21,8 @@ #include "libpty.h" #include "pty-int.h" -#if !defined(UTMP_FILE) && defined(_UTMP_PATH) -#define UTMP_FILE _UTMP_PATH +#if !defined(UTMP_FILE) && defined(_PATH_UTMP) +#define UTMP_FILE _PATH_UTMP #endif long pty_update_utmp (process_type, pid, username, line, host) @@ -124,7 +124,7 @@ long pty_update_utmp (process_type, pid, username, line, host) tty = ttyslot(); if (tty > 0 && (fd = open(UTMP_FILE, O_WRONLY, 0)) >= 0) { (void)lseek(fd, (off_t)(tty * sizeof(struct utmp)), SEEK_SET); - (void)write(fd, (char *)ent, sizeof(struct utmp)); + (void)write(fd, (char *)&ent, sizeof(struct utmp)); (void)close(fd); }