From 8575e2ba57892b49654ebf3dfa502c90e2b765b5 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Fri, 27 Jan 2017 10:26:34 +0000 Subject: 40425: HAVE_* tests for getutxent etc. Not yet 100% clear where the #if's go, depends on how various systems implement the old or new formats. --- Src/watch.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'Src/watch.c') diff --git a/Src/watch.c b/Src/watch.c index 7a6b930b9..6103ef15f 100644 --- a/Src/watch.c +++ b/Src/watch.c @@ -87,9 +87,12 @@ #if !defined(WATCH_STRUCT_UTMP) && defined(HAVE_STRUCT_UTMPX) && defined(REAL_UTMPX_FILE) # define WATCH_STRUCT_UTMP struct utmpx -# define setutent setutxent -# define getutent getutxent -# define endutent endutxent +# if defined(HAVE_SETUTXENT) && defined(HAVE_GETUTXENT) && defined(HAVE_ENDUTXENT) +# define setutent setutxent +# define getutent getutxent +# define endutent endutxent +# endif + /* * In utmpx, the ut_name field is replaced by ut_user. * Howver, on some systems ut_name may already be defined this -- cgit 1.4.1