mirror of
https://github.com/golang/go
synced 2024-11-21 16:04:45 -07:00
net: Fix inaccurate docs for AcceptTCP and AcceptUnix.
R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/13592043
This commit is contained in:
parent
640a57c881
commit
a3834a2e8a
@ -111,7 +111,7 @@ type TCPListener struct {
|
||||
}
|
||||
|
||||
// AcceptTCP accepts the next incoming call and returns the new
|
||||
// connection and the remote address.
|
||||
// connection.
|
||||
func (l *TCPListener) AcceptTCP() (*TCPConn, error) {
|
||||
if l == nil || l.fd == nil || l.fd.ctl == nil {
|
||||
return nil, syscall.EINVAL
|
||||
|
@ -225,7 +225,7 @@ type TCPListener struct {
|
||||
}
|
||||
|
||||
// AcceptTCP accepts the next incoming call and returns the new
|
||||
// connection and the remote address.
|
||||
// connection.
|
||||
func (l *TCPListener) AcceptTCP() (*TCPConn, error) {
|
||||
if l == nil || l.fd == nil {
|
||||
return nil, syscall.EINVAL
|
||||
|
@ -97,7 +97,7 @@ func ListenUnix(net string, laddr *UnixAddr) (*UnixListener, error) {
|
||||
}
|
||||
|
||||
// AcceptUnix accepts the next incoming call and returns the new
|
||||
// connection and the remote address.
|
||||
// connection.
|
||||
func (l *UnixListener) AcceptUnix() (*UnixConn, error) {
|
||||
return nil, syscall.EPLAN9
|
||||
}
|
||||
|
@ -275,7 +275,7 @@ func ListenUnix(net string, laddr *UnixAddr) (*UnixListener, error) {
|
||||
}
|
||||
|
||||
// AcceptUnix accepts the next incoming call and returns the new
|
||||
// connection and the remote address.
|
||||
// connection.
|
||||
func (l *UnixListener) AcceptUnix() (*UnixConn, error) {
|
||||
if l == nil || l.fd == nil {
|
||||
return nil, syscall.EINVAL
|
||||
|
Loading…
Reference in New Issue
Block a user