I’m going to try to explain what I mean using a few examples:
- socket() -> WSASocket()
- connect() -> WSAConnect()
- send() -> WSASend()
- sendto() -> WSASendTo()
- recv() -> WSARecv()
- recvfrom() -> WSARecvFrom()
- …
- closesocket() -> WSA???()
This is nothing that matters much, but is still something that gives me a splitting headache.
closesocket is only available on Windows, I’m not sure why they didn’t follow the WSA convention there though. If it really bothers you though you can make your own wrapper that calls closesocket.
As mentioned in WSASocket a call to closesocket should be made.