tevent: Fix multiple handler on the same fd bug in the tevent select backend.
authorJeremy Allison <jra@samba.org>
Wed, 27 Feb 2013 18:18:44 +0000 (10:18 -0800)
committerStefan Metzmacher <metze@samba.org>
Fri, 1 Mar 2013 17:51:52 +0000 (18:51 +0100)
commit1ffac78a05de5aeafc6bd403544ed6c1946504b2
tree5851b178ff424f0fe36dd8f169394d0c89044307
parent4f82b2a81688a862354674d6304cf572122a280b
tevent: Fix multiple handler on the same fd bug in the tevent select backend.

When we're deciding what handlers to call in the select backend,
we didn't take into account the fact that the same fd may have
been added into the read FD_SET and the write FD_SET but with
different handlers.

We must match on both the file descriptor and the flags requested
before calling the handler.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
lib/tevent/tevent_select.c