Move declatation of struct timespec to its own include files for

systems without it since it needs time_t defined.
This commit is contained in:
Todd C. Miller
2005-06-23 03:04:35 +00:00
parent 9800e99ffc
commit 3bb5c181b0
2 changed files with 3 additions and 7 deletions

View File

@@ -51,6 +51,9 @@
#include <time.h>
#include <pwd.h>
#include <grp.h>
#ifndef HAVE_TIMESPEC
# include <emul/timespec.h>
#endif
#include "sudo.h"

View File

@@ -255,13 +255,6 @@ const char *getprogname __P((void));
#endif /* HAVE___PROGNAME */
#endif /* !HAVE_GETPROGNAME */
#ifndef HAVE_TIMESPEC
struct timespec {
time_t tv_sec;
long tv_nsec;
};
#endif /* !HAVE_TIMESPEC */
#ifndef timespecclear
# define timespecclear(ts) (ts)->tv_sec = (ts)->tv_nsec = 0
#endif