6 ms·
Shouldn't sock.close() imply sock.shutdown() ? Isn't it pointless to call both?
by rix0r 5y ago
Shouldn't
sock.close()
imply
sock.shutdown()
? Isn't it pointless to call both?
- oogali 5y agohttps://beej.us/guide/bgnet/html/#close-and-shutdownget-outta-my-face https://beej.us/guide/bgnet/html/#close-and-shutdownget-outt...
- vadiml 5y agoYou're 100% right... In this case the shutdown is called with RDWR... so the author could simply call close!
- ptspts 5y agoIs there any case where a shutdown() right before a close() makes a difference?