git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
15da0b1
)
tevent: preferr the write handler if there're two possible handlers registered with...
author
Stefan Metzmacher
<metze@samba.org>
Wed, 20 Feb 2013 10:50:56 +0000
(11:50 +0100)
committer
Stefan Metzmacher
<metze@samba.org>
Fri, 1 Mar 2013 19:00:16 +0000
(20:00 +0100)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
lib/tevent/tevent_epoll.c
patch
|
blob
|
history
diff --git
a/lib/tevent/tevent_epoll.c
b/lib/tevent/tevent_epoll.c
index 41415b06e9aaf520ea90258a80b77946ef72cbc5..19f6809f2721731a8885d68aef8c9f57b2780438 100644
(file)
--- a/
lib/tevent/tevent_epoll.c
+++ b/
lib/tevent/tevent_epoll.c
@@
-702,6
+702,16
@@
static int epoll_event_loop(struct epoll_event_context *epoll_ev, struct timeval
if (events[i].events & EPOLLIN) flags |= TEVENT_FD_READ;
if (events[i].events & EPOLLOUT) flags |= TEVENT_FD_WRITE;
+ if (flags & TEVENT_FD_WRITE) {
+ if (fde->flags & TEVENT_FD_WRITE) {
+ mpx_fde = NULL;
+ }
+ if (mpx_fde && mpx_fde->flags & TEVENT_FD_WRITE) {
+ fde = mpx_fde;
+ mpx_fde = NULL;
+ }
+ }
+
if (mpx_fde) {
/* Ensure we got the right fde. */
if ((flags & fde->flags) == 0) {