1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00
Volker Lendecke 7f29f817fa 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
2010-06-10 11:24:00 +02:00
..
2009-09-11 15:39:52 +02:00
2009-02-16 08:53:25 +01:00
2009-08-19 11:39:44 +02:00
2010-02-22 21:45:32 +01:00
2009-09-25 11:00:19 -04:00
2009-02-16 08:53:25 +01:00