Are there any platforms where using structure copy on an fd_set (for select() or pselect()) causes problems?

前端 未结 5 1946
生来不讨喜
生来不讨喜 2020-11-28 15:05

The select() and pselect() system calls modify their arguments (the \'fd_set *\' arguments), so the input value tells the system which file descriptors to check

5条回答
  •  生来不讨喜
    2020-11-28 15:51

    I don't have enough rep to add this as a comment to caf's answer, but there are libraries to abstract over the non-standard interfaces like epoll() and kqueue. libevent is one, and libev another. I think GLib also has one that ties into its mainloop.

提交回复
热议问题