Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1181)

Unified Diff: src/pkg/net/tcpsock_posix.go

Issue 6002053: code review 6002053: net: fix race between Close and Read (Closed)
Patch Set: diff -r b25d41fa3e5f https://go.googlecode.com/hg/ Created 11 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/pkg/net/iprawsock_posix.go ('k') | src/pkg/net/udpsock_posix.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pkg/net/tcpsock_posix.go
===================================================================
--- a/src/pkg/net/tcpsock_posix.go
+++ b/src/pkg/net/tcpsock_posix.go
@@ -108,9 +108,7 @@
if !c.ok() {
return syscall.EINVAL
}
- err := c.fd.Close()
- c.fd = nil
- return err
+ return c.fd.Close()
}
// CloseRead shuts down the reading side of the TCP connection.
« no previous file with comments | « src/pkg/net/iprawsock_posix.go ('k') | src/pkg/net/udpsock_posix.go » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b