jorton 2003/01/03 09:47:07
Modified: poll/unix poll.c
Log:
Simplify select-based apr_poll to avoid an extra for loop and clear
rtnevents whilst building the fd_set.
Revision Changes Path
1.36 +2 -4 apr/poll/unix/poll.c
Index: poll.c
===================================================================
RCS file: /home/cvs/apr/poll/unix/poll.c,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- poll.c 3 Jan 2003 17:06:07 -0000 1.35
+++ poll.c 3 Jan 2003 17:47:07 -0000 1.36
@@ -217,6 +217,8 @@
for (i = 0; i < num; i++) {
apr_os_sock_t fd;
+ aprset[i].rtnevents = 0;
+
if (aprset[i].desc_type == APR_POLL_SOCKET) {
#ifdef NETWARE
if (HAS_PIPES(set_type)) {
@@ -274,10 +276,6 @@
#ifdef NETWARE
}
#endif
-
- for (i = 0; i < num; i++) {
- aprset[i].rtnevents = 0;
- }
(*nsds) = rv;
if ((*nsds) == 0) {