Changeset 28141 in vbox for trunk/src/VBox
- Timestamp:
- Apr 9, 2010 1:47:50 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Network/slirp/slirp.c
r28023 r28141 56 56 # define DO_POLL_EVENTS(rc, error, so, events, label) do {} while (0) 57 57 58 #if 0/** @todo This doesn't work because linux sets both POLLHUP and POLLERR when the 59 socket is closed. @bugref{4811} Please verif the changed test. */ 58 60 # define DO_CHECK_FD_SET(so, events, fdset) \ 59 61 ( ((so)->so_poll_index != -1) \ … … 62 64 && (polls[(so)->so_poll_index].revents & N_(fdset ## _poll)) \ 63 65 && !(polls[(so)->so_poll_index].revents & (POLLERR|POLLNVAL))) 66 #else 67 # define DO_CHECK_FD_SET(so, events, fdset) \ 68 ( ((so)->so_poll_index != -1) \ 69 && ((so)->so_poll_index <= ndfs) \ 70 && ((so)->s == polls[so->so_poll_index].fd) \ 71 && (polls[(so)->so_poll_index].revents & N_(fdset ## _poll)) \ 72 && !(polls[(so)->so_poll_index].revents & POLLNVAL)) 73 #endif 74 64 75 /* specific for Unix API */ 65 76 # define DO_UNIX_CHECK_FD_SET(so, events, fdset) DO_CHECK_FD_SET((so), (events), fdset) … … 1130 1141 if ( CHECK_FD_SET(so, NetworkEvents, xfds) 1131 1142 #ifdef RT_OS_DARWIN 1132 /* Darwin and probably BSD hosts generates POLLPRI|POLLHU Bevent on receiving TCP.flags.{ACK|URG|FIN} this1133 * combination on other Unixs hosts doesn't enter to this branch 1143 /* Darwin and probably BSD hosts generates POLLPRI|POLLHUP event on receiving TCP.flags.{ACK|URG|FIN} this 1144 * combination on other Unixs hosts doesn't enter to this branch 1134 1145 */ 1135 1146 && !CHECK_FD_SET(so, NetworkEvents, closefds) … … 1181 1192 Log2(("%R[natsock] errno %d:%s\n", so, errno, strerror(errno))); 1182 1193 break; 1183 } 1194 } 1184 1195 } 1185 1196 /* mark the socket for termination _after_ it was drained */
Note:
See TracChangeset
for help on using the changeset viewer.