Fix utempter #ifdefs.

This commit is contained in:
John Hood
2017-05-13 19:29:40 -04:00
parent c8580d1fb6
commit 4902970486
+2
View File
@@ -953,12 +953,14 @@ static bool motd_hushed( void )
return (0 == lstat( ".hushlogin", &buf )); return (0 == lstat( ".hushlogin", &buf ));
} }
#ifdef HAVE_UTMPX_H
static bool device_exists( const char *ut_line ) static bool device_exists( const char *ut_line )
{ {
string device_name = string( "/dev/" ) + string( ut_line ); string device_name = string( "/dev/" ) + string( ut_line );
struct stat buf; struct stat buf;
return (0 == lstat( device_name.c_str(), &buf )); return (0 == lstat( device_name.c_str(), &buf ));
} }
#endif
static void warn_unattached( const string & ignore_entry ) static void warn_unattached( const string & ignore_entry )
{ {