Let csh(1) use utmpx instead of utmp.

csh allows you to monitor the utmp(x) file to monitor certain user
logins. Unfortunately it needs to directly stat() this file. I don't
want to break this module , but eventually it shouldn't do that. The
idea of the getutxent(3) API is to hide file access.

Approved by:	mp
This commit is contained in:
Ed Schouten 2010-01-13 17:49:35 +00:00
parent a627ac61ab
commit d0632ec94a
2 changed files with 6 additions and 5 deletions

View File

@ -54,7 +54,7 @@
#define HAVE_GETPWENT 1
/* Define to 1 if you have the `getutent' function. */
/* #undef HAVE_GETUTENT */
#define HAVE_GETUTENT 1
/* Define if you have the iconv() function. */
/* #undef HAVE_ICONV */
@ -130,10 +130,10 @@
#define HAVE_STRUCT_UTMP_UT_HOST 1
/* Define to 1 if `ut_tv' is member of `struct utmp'. */
/* #undef HAVE_STRUCT_UTMP_UT_TV */
#define HAVE_STRUCT_UTMP_UT_TV 1
/* Define to 1 if `ut_user' is member of `struct utmp'. */
/* #undef HAVE_STRUCT_UTMP_UT_USER */
#define HAVE_STRUCT_UTMP_UT_USER 1
/* Define to 1 if `ut_xtime' is member of `struct utmp'. */
/* #undef HAVE_STRUCT_UTMP_UT_XTIME */
@ -159,10 +159,10 @@
#define HAVE_UNISTD_H 1
/* Define to 1 if you have the <utmpx.h> header file. */
/* #undef HAVE_UTMPX_H */
#define HAVE_UTMPX_H 1
/* Define to 1 if you have the <utmp.h> header file. */
#define HAVE_UTMP_H 1
/* #undef HAVE_UTMP_H */
/* Define to 1 if you have the <wchar.h> header file. */
#define HAVE_WCHAR_H 1

View File

@ -85,6 +85,7 @@
/* Use LC_MESSAGES locale category to open the message catalog */
#define MCLoadBySet NL_CAT_LOCALE
#define BUFSIZE 8192
#define UTMPX_FILE "/var/run/utx.active"
#endif
#if defined(__bsdi__)