2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 06:15:37 +00:00

Add support for libevent-style timed events. Adding a timed event

is currently O(n).  The only consumer of timed events is sudoreplay
which only used a singled one so O(n) == O(1) for now.  This also
allows us to remove the nanosleep compat function as we now use a
timeout event instead.
This commit is contained in:
Todd C. Miller
2013-10-28 10:00:09 -06:00
parent d8b368b503
commit 8861e01d16
16 changed files with 282 additions and 312 deletions

View File

@@ -186,13 +186,6 @@
#undef ISSET
#define ISSET(t, f) ((t) & (f))
/*
* Some systems define this in <sys/param.h> but we don't include that anymore.
*/
#ifndef howmany
# define howmany(x, y) (((x) + ((y) - 1)) / (y))
#endif
/*
* Older systems may be missing stddef.h and/or offsetof macro
*/
@@ -413,9 +406,6 @@ char *mkdtemp(char *);
#ifndef HAVE_MKSTEMPS
int mkstemps(char *, int);
#endif
#ifndef HAVE_NANOSLEEP
int nanosleep(const struct timespec *, struct timespec *);
#endif
#ifndef HAVE_PW_DUP
struct passwd *pw_dup(const struct passwd *);
#endif