diff options
Diffstat (limited to 'third_party/libevent/event-internal.h')
-rw-r--r-- | third_party/libevent/event-internal.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/third_party/libevent/event-internal.h b/third_party/libevent/event-internal.h index 7485f21..93ac568 100644 --- a/third_party/libevent/event-internal.h +++ b/third_party/libevent/event-internal.h @@ -71,7 +71,7 @@ struct event_base { }; /* Internal use only: Functions that might be missing from <sys/queue.h> */ -#ifndef HAVE_TAILQFOREACH +#if !defined(HAVE_TAILQFOREACH) || defined(__QUENTIN_BUILD__) #define TAILQ_FIRST(head) ((head)->tqh_first) #define TAILQ_END(head) NULL #define TAILQ_NEXT(elm, field) ((elm)->field.tqe_next) @@ -85,6 +85,9 @@ struct event_base { *(listelm)->field.tqe_prev = (elm); \ (listelm)->field.tqe_prev = &(elm)->field.tqe_next; \ } while (0) +#define TAILQ_LAST(head, headname) \ + (*(((struct headname *)((head)->tqh_last))->tqh_last)) +#define TAILQ_EMPTY(head) ((head)->tqh_first == NULL) #endif /* TAILQ_FOREACH */ int _evsignal_set_handler(struct event_base *base, int evsignal, |