summaryrefslogtreecommitdiff
path: root/src/pkg/net/udpsock_plan9.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/pkg/net/udpsock_plan9.go')
-rw-r--r--src/pkg/net/udpsock_plan9.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/pkg/net/udpsock_plan9.go b/src/pkg/net/udpsock_plan9.go
index f90a5fe9ab..d1f83d3848 100644
--- a/src/pkg/net/udpsock_plan9.go
+++ b/src/pkg/net/udpsock_plan9.go
@@ -43,7 +43,7 @@ func (c *UDPConn) SetWriteDeadline(t time.Time) error {
// after a fixed time limit; see SetDeadline and SetReadDeadline.
func (c *UDPConn) ReadFromUDP(b []byte) (n int, addr *UDPAddr, err error) {
if !c.ok() {
- return 0, nil, os.EINVAL
+ return 0, nil, syscall.EINVAL
}
if c.data == nil {
c.data, err = os.OpenFile(c.dir+"/data", os.O_RDWR, 0)
@@ -69,7 +69,7 @@ func (c *UDPConn) ReadFromUDP(b []byte) (n int, addr *UDPAddr, err error) {
// ReadFrom implements the PacketConn ReadFrom method.
func (c *UDPConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
if !c.ok() {
- return 0, nil, os.EINVAL
+ return 0, nil, syscall.EINVAL
}
return c.ReadFromUDP(b)
}
@@ -82,7 +82,7 @@ func (c *UDPConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
// On packet-oriented connections, write timeouts are rare.
func (c *UDPConn) WriteToUDP(b []byte, addr *UDPAddr) (n int, err error) {
if !c.ok() {
- return 0, os.EINVAL
+ return 0, syscall.EINVAL
}
if c.data == nil {
c.data, err = os.OpenFile(c.dir+"/data", os.O_RDWR, 0)
@@ -106,11 +106,11 @@ func (c *UDPConn) WriteToUDP(b []byte, addr *UDPAddr) (n int, err error) {
// WriteTo implements the PacketConn WriteTo method.
func (c *UDPConn) WriteTo(b []byte, addr Addr) (n int, err error) {
if !c.ok() {
- return 0, os.EINVAL
+ return 0, syscall.EINVAL
}
a, ok := addr.(*UDPAddr)
if !ok {
- return 0, &OpError{"write", c.dir, addr, os.EINVAL}
+ return 0, &OpError{"write", c.dir, addr, syscall.EINVAL}
}
return c.WriteToUDP(b, a)
}