2549 Commits

Author SHA1 Message Date
Kevin Bowling
ad03952edf Backport libevent to vanilla Autoconf 2.59 (as used in RHEL5) 2011-01-03 15:09:21 -07:00
Kevin Bowling
b3651d1576 Add an evconfig-private.h stub for Win32. 2011-01-02 08:48:12 -07:00
Kevin Bowling
dc628c0304 Add an include guard 2011-01-02 08:47:46 -07:00
Kevin Bowling
0915ca0aa6 Include evconfig-private.h in internal files for great good. 2011-01-02 08:43:45 -07:00
Kevin Bowling
f6d66bc716 Fix a comment warning and add evconfig-private.h to .gitignore 2011-01-02 08:05:33 -07:00
Kevin Bowling
9b27b30720 Remove event-private.h and switch to evconfig-private.h 2011-01-02 08:04:12 -07:00
Kevin Bowling
868f88874f Use a Configuration Header Template for evconfig-private.h 2011-01-02 07:51:23 -07:00
Kevin Bowling
edf62dddbc Revert "evconfig-private.h with recusive configure subdirs"
This reverts commit ed53d5ef8053af08186ef80dfc1647cff769fac8.
2011-01-02 07:29:45 -07:00
Kevin Bowling
ed53d5ef80 evconfig-private.h with recusive configure subdirs 2011-01-02 06:35:05 -07:00
Kevin Bowling
ea8fa4cb23 Add AC_GNU_SOURCE to the fallback case. 2011-01-02 05:14:41 -07:00
Nick Mathewson
ac6904241b Merge remote branch 'origin/patches-2.0' 2011-01-02 00:59:20 -05:00
Nick Mathewson
cb8059d2d3 Fix compilation on Windows with NDEBUG
Dongsheng Song reports that when building on windows with NDEBUG, you
run into an attempt to do EVUTIL_ASSERT(x) where x is a bitfield,
which turns into _EVUTIL_NIL_CONDITION(x), which takes sizeof(x),
which is illegal.  This patch fixes _EVUTIL_NIL_CONDITION to work on
bitfields too.
2011-01-02 00:56:01 -05:00
Nick Mathewson
b42ce4bf08 Fix evport handling of POLLHUP and POLLERR
In other backends, they make _all_ events trigger; with evport they
previously triggered nothing.  Found by Phua Keat Yee.
2011-01-01 21:17:31 -05:00
Kevin Bowling
c51ef9307a Eliminate a couple more manual internal _GNU_SOURCE defines 2010-12-22 23:24:01 -07:00
Kevin Bowling
3b265412b7 Remove internal usage of _GNU_SOURCE 2010-12-22 23:08:10 -07:00
Kevin Bowling
2c5566a9c7 Add event-private.h to noinst_HEADERS 2010-12-22 23:00:59 -07:00
Kevin Bowling
321b558793 Filter '# define' statements from autoconf and generate event-private.h 2010-12-22 22:53:03 -07:00
Kevin Bowling
1fa7dbe1e8 Add AC_USE_SYSTEM_EXTENSIONS to configure.in.
Requires follow on patches for correctness and robustness.
2010-12-22 22:11:26 -07:00
Nick Mathewson
41bb1cae79 Merge branch 'file_offset_v2' 2010-12-20 19:30:13 -05:00
Nick Mathewson
0aad01436a Refactor addfile tests; add test for big files and for offsets 2010-12-20 19:25:15 -05:00
Nick Mathewson
3f405d2d4b Add CreateFileMapping file_segment implementation for win32 2010-12-20 19:25:15 -05:00
Nick Mathewson
c2d9884a6a Add support for mmaps with nonzero offset values. Needs testing. 2010-12-20 19:25:15 -05:00
Nick Mathewson
e72afae068 Add evbuffer_add_file_segment() so one fd can be used efficiently in more than one evbuffer_add_file at a time 2010-12-20 19:25:05 -05:00
Nick Mathewson
076680abe4 Merge branch 'epoll_table_v2' 2010-12-16 14:37:15 -05:00
Nick Mathewson
d4970d4edd Reindent epoll_apply_one_change() 2010-12-16 14:37:05 -05:00
Nick Mathewson
2d55a190e1 Clean up error handling in epoll_apply_one_change() a little
The old code was more or less:
   if (op == X && errno == FOO) {
     ...
   } else if (op == Y && errno == BAR) {
     ...
   }
but really we wanted to do a switch (op) to avoid needless checks
and branches.

This patch leaves the indentation a little weird so as to make it
easier to see what changed; the next patch will fix the indentation.
2010-12-16 14:34:14 -05:00
Nick Mathewson
8c83eb6948 Replace big chain of if/thens in epoll.c with a table lookup
This should save a bunch of branches by doing instead a lookup in a
nice static table.

To ensure correctness, the table is generated from a Python script,
included with this commit.
2010-12-16 14:17:49 -05:00
Nick Mathewson
e30a82f118 Add event_enable_debug_logging() to control use of debug logs
Previously, debug logs were turned on if you built with -DUSE_DEBUG
and off otherwise.  This make builds with -DUSE_DEBUG hideously slow
and other builds unable to get debug logs.

This is based off a patch by Ralph Castain from October.  It tries a
little harder to avoid needless function calls, it doesn't require
stdbool, and makes the controlling parameter a mask rather than a
boolean so that we can later support enabling only the debugging
messages for the parts of Libevent you're trying to debug.
2010-12-16 13:58:56 -05:00
Nick Mathewson
b8b8aa560c Use GetSystemTimeAsFileTime to implement gettimeofday on win32.
It is (in my benchmarks) way faster than _ftime, though the
conversion process is not so straightforward.  In theory, it can
have a better granularity too, though in practice who knows what
you're getting.
2010-12-16 13:26:01 -05:00
Mike Smellie
04ba27ebf2 Use current event set rather than current pending change when deciding whether to no-op a del
This alters event_changelist_del to quash deletion of events that
didn't exist in the first place.

As far as I can see, the add,delete, dispatch case described in the
original comment will never happen.  The recorded change is a single
operation, not a queue.  This seems to leave actions to delete
events that never existed as the real targets for no-oping
2010-12-16 13:21:25 -05:00
Nick Mathewson
2570ae50d3 Bump version in master to 2.1.0-alpha-dev 2010-12-16 12:59:22 -05:00
Nick Mathewson
05f0195dd9 Bump version to 2.0.10-stable-dev 2010-12-16 12:57:23 -05:00
Nick Mathewson
5a12d83597 Add changelog for 2.0.10-stable release-2.0.10-stable 2010-12-16 12:32:35 -05:00
Nick Mathewson
d34d21d959 Add more acknowledgements to the readme for 2.0.10-stable 2010-12-15 14:30:04 -05:00
Nick Mathewson
bffc411ed6 Set the version to 2.0.10-stable 2010-12-15 14:29:50 -05:00
Evan Jones
b63ab1776b EVUTIL_ASSERT: Use sizeof() to avoid "unused variable" warnings. 2010-12-14 00:14:07 -05:00
Nick Mathewson
18adc3f015 Add stuff to whatsnew based on reading include changes since August. 2010-12-09 12:17:58 -05:00
Nick Mathewson
57689c4484 Document that the cpu_hint is only used on Windows with IOCP for now 2010-12-09 12:17:11 -05:00
Nick Mathewson
bb0d2b4e85 Consistentize tabs 2010-12-09 11:47:54 -05:00
Nick Mathewson
22f4af6580 Remove end-of-line whitespace 2010-12-09 11:43:12 -05:00
Nick Mathewson
74f75758cb tweak readme, whatsnew 2010-12-09 11:40:35 -05:00
Nick Mathewson
7011f9ec1f Fix a signed/unsigned comparison in the last commit 2010-12-07 11:45:14 -05:00
Constantine Verutin
d23839fc6e Reject overlong http requests early when Expect:100-continue is set 2010-12-07 11:43:52 -05:00
Evan Jones
c0bf63cecb tests: Use relative includes ("") instead of system includes (<>) 2010-12-03 12:57:15 -05:00
Evan Jones
4f332091c3 tests: Use new event2 headers instead of old compatibility headers. 2010-12-03 12:57:15 -05:00
Evan Jones
fbe64f216c Use relative includes instead of system includes consistently. 2010-12-02 11:03:55 -05:00
Evan Jones
ef5e65a484 bufferevent-internal.h: Use the new event2/util.h header, not evutil.h 2010-12-02 10:55:00 -05:00
Nick Mathewson
5beeec9d43 Correctly notify the main thread when activating an event from a subthread 2010-12-01 21:28:03 -05:00
Kelly Brock
2599b2d5f5 Minor fix for IOCP shutdown handling fix
Call setsockopt() on the actual new socket, not on as->s, which was
set to INVALID_SOCKET.
2010-11-30 11:34:26 -05:00
Nick Mathewson
2b0b06d7a3 Increment version to 2.0.9-rc-dev 2010-11-30 02:19:25 -05:00