| 390 | } |
| 391 | |
| 392 | void set(SOCKET handle) |
| 393 | { |
| 394 | #ifdef HAVE_POLL |
| 395 | FB_SIZE_T pos; |
| 396 | if (slct_poll.find(handle, pos)) |
| 397 | { |
| 398 | slct_poll[pos].events = SEL_INIT_EVENTS; |
| 399 | } |
| 400 | else |
| 401 | { |
| 402 | pollfd f; |
| 403 | f.fd = handle; |
| 404 | f.events = SEL_INIT_EVENTS; |
| 405 | slct_poll.insert(pos, f); |
| 406 | } |
| 407 | #else |
| 408 | FD_SET(handle, &slct_fdset); |
| 409 | #ifdef WIN_NT |
| 410 | ++slct_width; |
| 411 | #else |
| 412 | slct_width = MAX(slct_width, handle + 1); |
| 413 | #endif // WIN_NT |
| 414 | #endif // HAVE_POLL |
| 415 | } |
| 416 | |
| 417 | void clear() |
| 418 | { |
no test coverage detected