What client-side situations need bind()?

后端 未结 7 1565
长情又很酷
长情又很酷 2021-01-01 16:21

I\'m learning C socket programming. When would you use bind() on the client-side? What types of program will need it and why? Where can I find an example?

7条回答
  •  一生所求
    2021-01-01 16:40

    bind function is one of "key" functions. It associates your socket (server or client) with address (ip + port). As for Windows you must use bind for WinSockets. There is good book about it "Network Programming for Microsoft Windows" by Anthony Jones and Jim Ohlund.

提交回复
热议问题