Join GitHub today
net: unix/windows handling of netFD.Close is different #6074
> Comment #9 on issue #5792 by alex.brainman: net/rpc: data race on non-net > transport > https://golang.org/issue/5792 > > Dmitriy, > > While we're on this subject, I would like to talk to you about > (*netFD).Close. I could be wrong, but, I think, semantically windows and > unix (*netFD).Close are different. One waits for all outstanding IO to > finish, while the other does not. The questions here is: "What is guaranteed > on (*netFD).Close return? Can it be assumed that all outstanding IO is > completed and is flushed to OS or canceled? Can we be certain that OS socket > is closed?". Perhaps it is not important, but I would like to run this > concern by you. > > Alex
I don't know whether/when the Windows kernel sends a TCP RST packet when a process ends. If it ends with a normal exit status, the kernel should send normal shutdowns for all of them (so it won't be any different) If the process exits with an error, it might send RST, but I doubt we care there.
This issue was closed.