Skip to content

Commit

Permalink
Remove the redundant code to close listeners
Browse files Browse the repository at this point in the history
  • Loading branch information
panjf2000 committed Sep 19, 2019
1 parent 37965c4 commit ddbfc53
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gnet_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,9 @@ func activateReactors(svr *server, numLoops int) {
}

func (ln *listener) close() {
if ln.fd != 0 {
sniffError(unix.Close(ln.fd))
}
//if ln.fd != 0 {
// sniffError(unix.Close(ln.fd))
//}
if ln.f != nil {
sniffError(ln.f.Close())
}
Expand Down

0 comments on commit ddbfc53

Please sign in to comment.