I am using blocking sockets, so the function send() will block if the buffer gets too full. I will be using the Win API function send() to send data over the network. After the data is successfully sent, I want my program to immediately call closesocket(). Can I be assured that even if send() doesn't block, that the data has been successfully sent and that it is therefore safe to call closesocket()? Or, if it doesn't block, might it return too quickly, and therefore allow the closesocket() function to be called too soon, resulting in the socket closing before the data actually gets sent, and thus preventing the data from actually being sent?