You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by in...@ariel-networks.com on 2001/10/10 17:16:20 UTC

[PATCH] apr_poll_socket_mask() bug fix

Hi,

[network_io/unix/poll.c]
This is almost same as the fix of revision 1.49.

[include/arch/unix/networkio.h]
I think the two member variables are useless if we use poll(2).


Thanks.
=======
- INOUE Seiichiro <in...@ariel-networks.com>
  http://www.ariel-networks.com



Index: poll.c
===================================================================
RCS file: /home/cvspublic/apr/network_io/unix/poll.c,v
retrieving revision 1.49
diff -u -r1.49 poll.c
--- poll.c	2001/10/02 18:51:17	1.49
+++ poll.c	2001/10/10 14:53:09
@@ -180,8 +180,8 @@
         return APR_NOTFOUND;
     } 
     newevents = get_event(events);
-    if (aprset->events[i] & newevents) {
-        aprset->events[i] ^= newevents;
+    if (aprset->pollset[i].events & newevents) {
+        aprset->pollset[i].events ^= newevents;
     }
 
     return APR_SUCCESS;


Index: networkio.h
===================================================================
RCS file: /home/cvspublic/apr/include/arch/unix/networkio.h,v
retrieving revision 1.48
diff -u -r1.48 networkio.h
--- networkio.h	2001/07/16 20:36:59	1.48
+++ networkio.h	2001/10/10 15:07:11
@@ -152,10 +152,9 @@
     fd_set *read_set;
     fd_set *write_set;
     fd_set *except_set;
-#endif
     apr_int16_t *events;
     apr_int16_t *revents;
-
+#endif
 };
 
 const char *apr_inet_ntop(int af, const void *src, char *dst, apr_size_t size);