Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
rix0r
· 4y ago · 0 comments
Shouldn't
sock.close()
imply
sock.shutdown()
? Isn't it pointless to call both?
Comments
[–]
oogali
4y ago
https://beej.us/guide/bgnet/html/#close-and-shutdownget-outt...
[–]
vadiml
4y ago
You're 100% right... In this case the shutdown is called with RDWR... so the author could simply call close!
[–]
ptspts
4y ago
Is there any case where a shutdown() right before a close() makes a difference?