diff options
author | Volker Lendecke <vl@samba.org> | 2010-06-10 09:41:11 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2010-06-10 11:24:00 +0200 |
commit | 7f29f817fa939ef1bbb740584f09e76e2ecd5b06 (patch) | |
tree | 2947be828913c96b0217701e05e2308d8345ad15 /source3 | |
parent | 9fdb69ebcdca9e56e39affd7a35d1ccb28daad5c (diff) | |
download | samba-7f29f817fa939ef1bbb740584f09e76e2ecd5b06.tar.gz samba-7f29f817fa939ef1bbb740584f09e76e2ecd5b06.tar.bz2 samba-7f29f817fa939ef1bbb740584f09e76e2ecd5b06.zip |
tevent: Fix maxfd calculation in tevent_select
When doing
fd1 = tevent_add_fd(ev, ev, 2, 0, NULL, NULL);
fd2 = tevent_add_fd(ev, ev, 3, 0, NULL, NULL);
TALLOC_FREE(fd2);
fd2 = tevent_add_fd(ev, ev, 1, 0, NULL, NULL);
we end up with select_ev->maxfd==1. This is wrong.
An alternative fix might be to make select_ev->maxfd an unsigned int and make
EVENT_INVALID_MAXFD==UINT_MAX. But in theory we might end up with an fd of
UINT_MAX.
std_event_add_fd() contains exactly the same piece of code, so I'm directly
pushing it.
Volker
Diffstat (limited to 'source3')
0 files changed, 0 insertions, 0 deletions