]> granicus.if.org Git - libevent/commitdiff
Remove the last vestiges of _EVENT_USE_EVENTLIST
authorNick Mathewson <nickm@torproject.org>
Mon, 20 Feb 2012 19:07:08 +0000 (14:07 -0500)
committerNick Mathewson <nickm@torproject.org>
Mon, 20 Feb 2012 19:07:08 +0000 (14:07 -0500)
event-internal.h
event.c
include/event2/event_struct.h

index 56f1750b0375588c6ce39f10b7fa2cbb8c38ca97..bce9c386d0cc40a5d726dcf95bd5e6be4a88f7fc 100644 (file)
@@ -233,11 +233,6 @@ struct event_base {
        /** Mapping from signal numbers to enabled (added) events. */
        struct event_signal_map sigmap;
 
-#ifdef _EVENT_USE_EVENTLIST
-       /** All events that have been enabled (added) in this event_base */
-       struct event_list eventqueue;
-#endif
-
        /** Stored timeval; used to detect when time is running backwards. */
        struct timeval event_tv;
 
diff --git a/event.c b/event.c
index 5a54a9f4e78ecb22b2d6536c2b064737a5e7c2a0..bdcb8cd746b91c8b8321f13e15b486b0372336b2 100644 (file)
--- a/event.c
+++ b/event.c
@@ -588,9 +588,7 @@ event_base_new_with_config(const struct event_config *cfg)
        gettime(base, &base->event_tv);
 
        min_heap_ctor(&base->timeheap);
-#ifdef _EVENT_USE_EVENTLIST
-       TAILQ_INIT(&base->eventqueue);
-#endif
+
        base->sig.ev_signal_pair[0] = -1;
        base->sig.ev_signal_pair[1] = -1;
        base->th_notify_fd[0] = -1;
@@ -815,10 +813,6 @@ event_base_free(struct event_base *base)
 
        mm_free(base->activequeues);
 
-#ifdef _EVENT_USE_EVENTLIST
-       EVUTIL_ASSERT(TAILQ_EMPTY(&base->eventqueue));
-#endif
-
        evmap_io_clear(&base->io);
        evmap_signal_clear(&base->sigmap);
        event_changelist_freemem(&base->changelist);
@@ -2629,9 +2623,6 @@ event_queue_remove_inserted(struct event_base *base, struct event *ev)
        }
        DECR_EVENT_COUNT(base, ev);
        ev->ev_flags &= ~EVLIST_INSERTED;
-#ifdef _EVENT_USE_EVENTLIST
-       TAILQ_REMOVE(&base->eventqueue, ev, ev_next);
-#endif
 }
 static void
 event_queue_remove_active(struct event_base *base, struct event *ev)
@@ -2735,10 +2726,6 @@ event_queue_insert_inserted(struct event_base *base, struct event *ev)
        INCR_EVENT_COUNT(base, ev);
 
        ev->ev_flags |= EVLIST_INSERTED;
-
-#ifdef _EVENT_USE_EVENTLIST
-       TAILQ_INSERT_TAIL(&base->eventqueue, ev, ev_next);
-#endif
 }
 
 static void
index d3ca44d480366b0edaa2cd1ffd2e9da2b1180043..2da11e2ffc83d56f3c9134ad82e976d8784fc53e 100644 (file)
@@ -96,9 +96,7 @@ struct {                                                              \
 struct event_base;
 struct event {
        TAILQ_ENTRY(event) ev_active_next;
-#ifdef _EVENT_USE_EVENTLIST
-       TAILQ_ENTRY(event) ev_next;
-#endif
+
        /* for managing timeouts */
        union {
                TAILQ_ENTRY(event) ev_next_with_common_timeout;