From: Jim Meyering Date: Wed, 5 May 1999 13:34:18 +0000 (+0000) Subject: (read_utmp): Use the new definitions. X-Git-Tag: TEXTUTILS-1_22k~28 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9f8bc128f016191cf4c9649bccee2a052ccb66e5;p=thirdparty%2Fcoreutils.git (read_utmp): Use the new definitions. --- diff --git a/lib/readutmp.c b/lib/readutmp.c index 9fb4442c30..f395352994 100644 --- a/lib/readutmp.c +++ b/lib/readutmp.c @@ -70,12 +70,12 @@ read_utmp (const char *filename, int *n_entries, STRUCT_UTMP **utmp_buf) Solaris' utmpname returns 1 upon success -- which is contrary to what the GNU libc version does. In addition, older GNU libc versions are actually void. */ - utmpname (filename); + UTMP_NAME_FUNCTION (filename); - setutent (); + SET_UTMP_ENT (); n_read = 0; - while ((u = getutent ()) != NULL) + while ((u = GET_UTMP_ENT ()) != NULL) { ++n_read; utmp = (STRUCT_UTMP *) realloc (utmp, n_read * sizeof (STRUCT_UTMP)); @@ -84,7 +84,7 @@ read_utmp (const char *filename, int *n_entries, STRUCT_UTMP **utmp_buf) utmp[n_read - 1] = *u; } - endutent (); + END_UTMP_ENT (); *n_entries = n_read; *utmp_buf = utmp;