Remove use of AC_HEADER_TIME, only obsolete platforms actually

need this.  Also stop removing sys/time.h unless the source file
uses struct timeval.
This commit is contained in:
Todd C. Miller
2018-01-17 09:52:15 -07:00
parent b161ebe62d
commit a885b952fb
23 changed files with 80 additions and 167 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014-2015 Todd C. Miller <Todd.Miller@sudo.ws>
* Copyright (c) 2014-2018 Todd C. Miller <Todd.Miller@sudo.ws>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -21,9 +21,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#ifdef TIME_WITH_SYS_TIME
# include <time.h>
#endif
#include <time.h>
#include <errno.h>
#if defined(__MACH__) && !defined(HAVE_CLOCK_GETTIME)

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2001, 2003, 2004, 2008-2011, 2013, 2015, 2017
* Copyright (c) 2001, 2003, 2004, 2008-2011, 2013, 2015, 2017, 2018
* Todd C. Miller <Todd.Miller@sudo.ws>
*
* Permission to use, copy, modify, and distribute this software for any
@@ -38,9 +38,7 @@
#endif /* HAVE_STRINGS_H */
#include <ctype.h>
#include <unistd.h>
#ifdef TIME_WITH_SYS_TIME
# include <time.h>
#endif
#include <time.h>
#include "sudo_compat.h"
#include "pathnames.h"

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2009-2011, 2013, 2017 Todd C. Miller <Todd.Miller@sudo.ws>
* Copyright (c) 2009-2011, 2013, 2017-2018 Todd C. Miller <Todd.Miller@sudo.ws>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -23,9 +23,7 @@
#ifdef HAVE_SYS_SELECT_H
#include <sys/select.h>
#endif /* HAVE_SYS_SELECT_H */
#if TIME_WITH_SYS_TIME
# include <time.h>
#endif
#include <time.h>
#include <errno.h>
#include "sudo_compat.h"

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015 Todd C. Miller <Todd.Miller@sudo.ws>
* Copyright (c) 2015, 2018 Todd C. Miller <Todd.Miller@sudo.ws>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -23,9 +23,7 @@
#include <sys/time.h>
#include <stdio.h>
#include <errno.h>
#ifdef TIME_WITH_SYS_TIME
# include <time.h>
#endif
#include <time.h>
#if !defined(HAVE_UTIMES) || defined(HAVE_FUTIME)
# include <utime.h>
#endif