Branch :
| Author | Commit | Date | CI | Message |
|---|---|---|---|---|
| 899c1dcc | 2010-04-14 15:42:57 | Replace EVUTIL_CLOSESOCKET macro with a function The EVUTIL_CLOSESOCKET() macro required you to include unistd.h in your source for POSIX. We might as well turn it into a function: an extra function call is going to be cheap in comparison with the system call. We retain the EVUTIL_CLOSESOCKET() macro as an alias for the new evutil_closesocket() function. (commit message from email by Nick and Sebastian) | ||
| 657d1b6d | 2010-03-13 01:06:57 | Set mem_offset for every bufferevent type | ||
| 17efc1cd | 2010-03-04 01:25:51 | Update all our copyright notices to say "2010" | ||
| 23170a69 | 2010-02-25 16:57:57 | Fix mingw compilation | ||
| d3288293 | 2010-02-20 18:44:35 | Provide consistent, tested semantics for bufferevent timeouts The different bufferevent implementations had different behavior for their timeouts. Some of them kept re-triggering the timeouts indefinitely; some disabled the event immediately the first time a timeout triggered. Some of them made the timeouts only count when the bufferevent was actively trying to read or write; some did not. The new behavior is modeled after old socket bufferevents, since they were here first and their behavior is relatively sane. Basically, each timeout disables the bufferevent's corresponding read or write operation when it fires. Timeouts are stopped whenever we suspend writing or reading, and reset whenever we unsuspend writing or reading. Calling bufferevent_enable resets a timeout, as does changing the timeout value. | ||
| e5cf9879 | 2010-02-18 17:46:56 | Clean up formatting: remove trailing spaces | ||
| e5bbd40a | 2010-02-18 17:41:15 | Clean up formatting: use tabs, not 8-spaces, to indent. | ||
| cef61a2f | 2010-01-26 12:08:17 | Use ev_[u]intptr_t types in place of [u]intptr_t | ||
| ff3f6cd4 | 2010-01-22 16:14:49 | Check more internal event_add() calls for failure Most of these should be unable to fail, since adding a timeout generally always works. Still, it's better not to try to be "too smart for our own good here." There are some remaining event_add() calls that I didn't add checks for; I've marked those with "XXXX" comments. | ||
| ba2945f9 | 2010-01-06 17:59:44 | Merge branch 'ratelimit' Conflicts: bufferevent_async.c | ||
| 165d30e3 | 2009-12-30 14:29:56 | Fix compilation of rate-limiting code on win32. | ||
| 2e8eeea3 | 2009-12-29 19:50:03 | Fix crash bugs when a bufferevent's eventcb is not set. In many places throughout the code, we called _bufferevent_run_eventcb without checking whether the eventcb was actually set. This would work fine when the bufferevent's callbacks were deferred, but otherwise the code would segfault. Strangely, we always remembered to check before calling the _bufferevent_run_{read,write}cb functions. To prevent similar errors in the future, all of _buferevent_run_{read,write,event}cb now check to make sure the callback is actually set before invoking or deferring the callback. This patch also removes the now-redundant checks for {read,write}cb. | ||
| 737c9cd8 | 2009-11-27 13:16:54 | Rate-limiting for bufferevents; group and individual limits are supported. The fairness algorithms are not the best, not every bufferevent type is supported, and some of the locking tricks here are simply absurd. Still, this code should be a good first step. | ||
| d7d1f1da | 2009-11-17 20:31:09 | Move responsibility for IOCP callback into bufferevent_async. This patch from Chris Davis saves some callback depth, and adds proper ref-counting to bufferevents when there's a deferred evbuffer callback inflight. It could use a couple more comments to really nail down what its invariants are. svn:r1543 | ||
| 86db1c85 | 2009-11-04 05:19:26 | Commit ConnectEx code to get connect working with async bufferevents. This is code by Chris Davis, with changes to get the unit tests failing less aggressively. The unit tests for this code do not completely pass yet; Chris is looking into that. If they aren't passing by the next release, I'll turn off this code. svn:r1499 | ||
| 2e36dbe1 | 2009-10-26 20:00:43 | Use EVUTIL_ASSERT() consistently instead of assert. svn:r1464 | ||
| 879420a7 | 2009-10-23 22:00:29 | Expose a narrow window to the IOCP code. svn:r1459 | ||
| a62283a9 | 2009-07-17 17:46:17 | Always hold a reference to a bufferevent when calling its callbacks. Rationale: we hold a lock on the bufferevent when its callbacks are executing, so we need to release the lock afterwards. But the callback might free the bufferevent, so unless we're holding a reference on the bufferevent, the lock might not be there for us to release. svn:r1347 | ||
| 34574db0 | 2009-05-25 23:10:23 | Add a generic mechanism to implement timeouts in bufferevents. Paired and asynchronous bufferevents didn't do timeouts, and filtering bufferevents gave them funny semantics. Now they all should all work in a way consistent with what socket bufferevents do now: a [read/write] timeout triggers if [reading/writing] is enabled, and if the timeout is set, and the right amount of time passes without any data getting [added to the input buffer/drained from the output buffer]. svn:r1314 | ||
| 31d89f27 | 2009-05-13 20:37:21 | Add a "ctrl" mechanism to bufferevents for property access. OpenSSL uses something like this to implement get/set access for properties on its BIOs, so that it doesn't need to add a pair of get/set functions to the vtable struct for every new abstract property it provides an accessor for. Doing this lets us make bufferevent_setfd abstract, and implement an abstract bufferevent_getfd. svn:r1284 | ||
| a8bcbfd4 | 2009-05-06 02:33:37 | Fix bufferevent_async to use lock/unlock, not unlock/unlock. You do NOT want to know what windows does when you unlock a lock that is already unlocked. svn:r1278 | ||
| fe47003d | 2009-05-05 16:52:37 | Make unit tests for bufferevent_async compile and _almost_ work. Either I need to make the callbacks get deferred in a base with no events (doable), or I need to make it okay to call launch_read from inside the callback for read (tricky). svn:r1277 | ||
| 02801e5b | 2009-05-05 15:36:28 | Add a trival start of a be_async test. svn:r1276 | ||
| b69d03b5 | 2009-05-05 14:18:14 | Add a constructor for bufferevent_async. svn:r1274 | ||
| 5a3eddf0 | 2009-05-02 16:24:05 | Use fewer _compat.h headers in our own code. svn:r1268 | ||
| 1aebcd50 | 2009-05-01 01:42:33 | Initial core implementation of bufferevent_async.c svn:r1263 |