Azat Khuzhin
9a9b92ed06
Add EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD flag ( fixes : #958 )
...
By default we are using CLOCK_MONOTONIC_COARSE, but if
EVENT_BASE_FLAG_PRECISE_TIMER isset, then CLOCK_MONOTONIC will be used,
however this will also enable timerfd, while this is not always what
someone wants, hence add a flag to control this (by default the old
behavior is preserved, set new flag to change it).
2020-03-01 18:03:46 +03:00
yuangongji
620a3fa1d5
Doxygen documentation improvements
...
- Documentation for `bufferevent_compat.h` and `rpc.h` is not generated
since the `@file` command is missing. It can be fixed by adding
`@file` in file comment block.
- The briefs of buffer.h,bufferevent.h and some other files are missing.
Adding `@brief` command can fix it.
- The parameters in the function declaration are different from the
parameters following the `@param` command.We should change them to the
same.
- Documentation of `watch.h` is not generated since `watch.h` has not
been added to the Doxyfile `INPUT` tag.
- Add link to the watch.h in event.h
2019-08-29 23:08:12 +03:00
yuangongji
c03dabd76a
typo error in header file
2019-05-31 02:12:55 +08:00
Azat Khuzhin
55f9863b18
Remove experimental note for finalizers API
2019-04-07 04:57:32 +03:00
John Ohl
62df1301ca
Add support for EV_TIMEOUT to event_base_active_by_fd
...
Closes : #194 (cherry-pick)
2019-03-03 23:42:03 +03:00
Xiaozhou Liu
30d77f1b59
Fix typo
...
Closes : #658
2018-07-30 00:50:32 +03:00
Philip Prindeville
d2acf67ec3
Add convenience macros for user-triggered events
...
Signed-off-by: Philip Prindeville <philipp@redfish-solutions.com>
Closes : #647 (picked)
2018-06-18 03:13:12 +03:00
Dmitry Alimov
f24b28e4af
Fix typos in comments
2018-01-15 17:30:08 +03:00
Azat Khuzhin
e83443ec67
Merge remote-tracking branch 'official/pr/527' -- documentation fixes
...
* official/pr/527:
Fix a few trivial documentation typos
Clarify event_free() documentation regarding pending/active events
2017-07-16 21:40:18 +03:00
Nikolay Edigaryev
c3a61a13d7
Fix a few trivial documentation typos
2017-07-07 01:24:26 +05:00
Nikolay Edigaryev
2137886d2f
Clarify event_free() documentation regarding pending/active events
...
Currently it's not clear as to whether "first make it non-pending and
non-active" sentence requires user to take some action (e.g. call event_del(),
which event_free() already does internally) or just describes what this
function does from the developer point of view.
2017-07-07 01:22:43 +05:00
Nikolay Edigaryev
808524252f
Document some obvious cases where a function might also return NULL
...
Closes : #525
2017-07-02 13:16:59 +03:00
Andrea Shepard
f2645f80c1
Implement new/free for struct evutil_monotonic_timer and export monotonic time functions
2014-12-04 09:30:20 -05:00
Trond Norbye
4545fa9b68
Add option to build shared library
2014-02-25 14:57:24 +01:00
Nick Mathewson
53d279389a
Expand EV_CLOSED documentation a bit
2014-01-21 15:44:05 -05:00
Diego Giagio
b1b69ac7c1
Implemented EV_CLOSED event for epoll backend (EPOLLRDHUP).
...
- Added new EV_CLOSED event - detects premature connection close
by clients without the necessity of reading all the pending
data. Does not depend on EV_READ and/or EV_WRITE.
- Added new EV_FEATURE_EARLY_CLOSED feature for epoll.
Must be supported for listening to EV_CLOSED event.
- Added new regression test: test-closed.c
- All regression tests passed (test/regress and test/test.sh)
- strace output of test-closed using EV_CLOSED:
socketpair(PF_LOCAL, SOCK_STREAM, 0, [6, 7]) = 0
sendto(6, "test string\0", 12, 0, NULL, 0) = 12
shutdown(6, SHUT_WR) = 0
epoll_ctl(3, EPOLL_CTL_ADD, 7, {EPOLLRDHUP, {u32=7, u64=7}}) = 0
epoll_wait(3, {{EPOLLRDHUP, {u32=7, u64=7}}}, 32, 3000) = 1
epoll_ctl(3, EPOLL_CTL_MOD, 7, {EPOLLRDHUP, {u32=7, u64=7}}) = 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 4), ...})
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYM...
write(1, "closed_cb: detected connection close "..., 45) = 45
2014-01-17 23:20:42 -02:00
Nick Mathewson
f9e091bf4e
Merge remote-tracking branch 'asweeny86/event-count-max'
2014-01-06 12:11:30 -05:00
Andrew Sweeney
5173bef50f
Add access to max event count stats
...
This commit provides an interface for accessing and resetting the maximum
number of events in a given period. This information provides better insight
into event queue pressure.
2013-12-30 14:06:20 -05:00
Nick Mathewson
b4ef3def6f
Merge remote-tracking branch 'mistotebe/bufferevent_trigger'
2013-12-24 10:33:58 -05:00
Nick Mathewson
87fa2b004a
Unit tests for active_by_fd; unsupport active_by_fd(TIMEOUT)
...
[It turns out that event_base_active_by_fd(TIMEOUT) didn't actually
work right. Feel free to add it back in as a patch.]
2013-12-23 20:46:38 -05:00
Nick Mathewson
486594337a
Add event_base_active_by_signal by analogy
2013-12-21 23:32:10 -05:00
Nick Mathewson
5c9da9a8a8
Sanity-check arguments to event_base_active_by_fd()
2013-12-21 23:21:33 -05:00
Nick Mathewson
93369ff4e9
Merge remote-tracking branch 'ghazel/event_base_active_by_fd'
2013-12-21 23:15:41 -05:00
Nick Mathewson
db7acd1310
Merge remote-tracking branch 'origin/patches-2.0'
2013-12-20 13:37:39 -05:00
Nick Mathewson
eaa79cd459
Merge remote-tracking branch 'sourceforge/patches-2.0' into patches-2.0
...
Conflicts:
include/event2/event.h
2013-12-20 13:37:04 -05:00
Nick Mathewson
8cd695bf6d
Typo fixes from Linus Nordberg
2013-12-20 13:35:03 -05:00
Nick Mathewson
cec62cb80a
Typo fixes from Linus Nordberg
2013-12-20 13:31:29 -05:00
Nick Mathewson
031a803071
Clarify event_base_loop exit conditions
2013-12-16 12:02:21 -05:00
Ondřej Kuzník
be7bf2c768
Fix a typo
2013-12-03 23:39:13 +00:00
Nick Mathewson
ccf432b912
Try another doxygen tweak
2013-11-21 11:47:34 -05:00
Nick Mathewson
6e67b51023
Small doxygen tweaks
2013-11-21 11:30:04 -05:00
Mobai Zhang
0fa107d8cb
Added event_base_get_num_events()
2013-07-02 16:01:02 -04:00
Nick Mathewson
8415b69d42
Mark the finalize stuff as experiemental in case it needs to change
2013-04-30 11:44:25 -04:00
Nick Mathewson
920a5e69b0
Clarify an important point about event_base_foreach_event()
2013-04-26 19:15:50 -04:00
Nick Mathewson
5d11f4f39a
Make the event_finalize* functions return an error code
2013-04-26 12:18:38 -04:00
Nick Mathewson
a800b913ac
More documentation for finalization feature
2013-04-26 12:18:38 -04:00
Nick Mathewson
e9ebef83a0
Always run pending finalizers when event_base_free() is called
...
There was actually a bug in the original version of this: it tried to
run the finalizers after (potentially) setting current_base to NULL;
but those finalizers could themselves (potentially) be invoking stuff
that needed to know about the current event_base. So the right time to
do it is _before_ clearing current_base.
2013-04-26 12:18:07 -04:00
Nick Mathewson
8eedeabe50
Implement event_finalize() and related functions to avoid certain deadlocks
2013-04-26 12:18:07 -04:00
Volker Lendecke
0c2bacca43
Fix typo : Dispatching instead of Dispaching
2013-01-17 10:22:33 -05:00
Greg Hazel
865a14261c
event_base_active_by_fd
2013-01-16 16:31:08 -08:00
Nick Mathewson
dc0287c473
Clean up and clarify a little more documentation
2012-11-18 19:32:41 -05:00
Nick Mathewson
96584866cd
Avoid defining recommended functions in terms of deprecated ones
2012-11-18 18:59:19 -05:00
Nick Mathewson
e3b2e0869e
Add an event_remove_timer() to remove timer on an event without deleting it
2012-11-16 16:43:17 -05:00
Nick Mathewson
c181399e92
Merge remote-tracking branch 'azat/fix-typo-evets'
2012-11-16 10:53:52 -05:00
Nick Mathewson
c17dd59191
Free dangling event_once objects on event_base_free()
...
This patch makes us keep event_once objects in a doubly linked list
so we can free any once that haven't triggered when we call
event_base_free().
2012-11-16 10:05:04 -05:00
Azat Khuzhin
05f1aca598
Fix typo : events instead of evets
2012-09-18 15:17:29 +04:00
Nick Mathewson
232055ef49
Tweak patch for event_base_foreach_event()
...
* Fix whitespace
* Explain return value from callback function
* Reinstate return value so that caller can tell whether forech
exited early.
* Rename event_base_foreach_event_() to
event_base_foreach_event_nolock_().
* Use event_base_foreach_event_cb_fn typedef in more places
* Be more dire about undefined behavior.
2012-09-07 09:58:24 -04:00
Roman Puls
84fd6d7506
Expose event_base_foreach_event() as a public API.
2012-09-07 09:47:50 -04:00
Nick Mathewson
8a739b3492
Merge branch '21_event_callback_v3'
2012-06-28 11:36:52 -04:00
Nick Mathewson
9444524f85
Make it more clear that NOLOCK means "I promise, no multithreading"
2012-05-14 11:10:51 -04:00