aboutsummaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorMatt Layher <mdlayher@gmail.com>2021-08-09 17:12:37 -0400
committerMatt Layher <mdlayher@gmail.com>2021-08-16 16:58:24 +0000
commita0adf91d85bcb10fac394da063c8abc1c60d8eb2 (patch)
treed9c9b17a5ca51088ba6377c4e311f61714c9d013 /src/net
parent5a401001417151649363a4b2fbd658f3f1957cba (diff)
downloadgo-a0adf91d85bcb10fac394da063c8abc1c60d8eb2.tar.gz
go-a0adf91d85bcb10fac394da063c8abc1c60d8eb2.zip
internal/syscall/unix: change Ioctl arg type to unsafe.Pointer on AIX
Without this change, this code is technically in violation of the unsafe.Pointer rules since the conversion from unsafe.Pointer to uintptr has to happen when calling into the syscall6 assembly implementation. Change-Id: I4821f5bf9788c8fa2efeb041f811ed092e07ae74 Reviewed-on: https://go-review.googlesource.com/c/go/+/340949 Trust: Matt Layher <mdlayher@gmail.com> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/net')
-rw-r--r--src/net/interface_aix.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net/interface_aix.go b/src/net/interface_aix.go
index 49f78c2abb..7ad45d1175 100644
--- a/src/net/interface_aix.go
+++ b/src/net/interface_aix.go
@@ -78,7 +78,7 @@ func interfaceTable(ifindex int) ([]Interface, error) {
// Retrieve MTU
ifr := &ifreq{}
copy(ifr.Name[:], ifi.Name)
- err = unix.Ioctl(sock, syscall.SIOCGIFMTU, uintptr(unsafe.Pointer(ifr)))
+ err = unix.Ioctl(sock, syscall.SIOCGIFMTU, unsafe.Pointer(ifr))
if err != nil {
return nil, err
}