Select function in socket programming

前端 未结 5 1826
情歌与酒
情歌与酒 2020-12-03 07:44

Can anyone tell me the use and application of select function in socket programming in c?

5条回答
  •  旧巷少年郎
    2020-12-03 08:33

    select() is the low-tech way of polling sockets for new data to read or for an open TCP window to write. Unless there's some compelling reason not to, you're probably better off using poll(), or epoll_wait() if your platform has it, for better performance.

提交回复
热议问题