summaryrefslogtreecommitdiff
path: root/poll.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2009-11-18 21:16:33 +0000
committerNick Mathewson <nickm@torproject.org>2009-11-18 21:16:33 +0000
commit767eb70f5016cf65c3fad8e91ded8b4362bc79b0 (patch)
tree836effbeabe61357a235786d71eac68380a3a09f /poll.c
parentd7d1f1da09f32a14ff4c08dc0f1f0e0673ed5afd (diff)
downloadlibevent-767eb70f5016cf65c3fad8e91ded8b4362bc79b0.tar.gz
Fix compilation with threading disabled.
svn:r1546
Diffstat (limited to 'poll.c')
-rw-r--r--poll.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/poll.c b/poll.c
index d87bbdc6..cbfb42f6 100644
--- a/poll.c
+++ b/poll.c
@@ -125,6 +125,7 @@ poll_dispatch(struct event_base *base, struct timeval *tv)
nfds = pop->nfds;
+#ifndef _EVENT_DISABLE_THREAD_SUPPORT
if (base->th_base_lock) {
/* If we're using this backend in a multithreaded setting,
* then we need to work on a copy of event_set, so that we can
@@ -147,6 +148,9 @@ poll_dispatch(struct event_base *base, struct timeval *tv)
} else {
event_set = pop->event_set;
}
+#else
+ event_set = pop->event_set;
+#endif
if (tv != NULL)
msec = tv->tv_sec * 1000 + (tv->tv_usec + 999) / 1000;