mirror of
https://github.com/golang/net.git
synced 2026-03-31 10:27:08 +09:00
route: avoid unnecessary type conversions
CL generated mechanically with github.com/mdempsky/unconvert. Change-Id: I22eea0b991462dd00f3fa28073a8b886e19bc068 Reviewed-on: https://go-review.googlesource.com/100095 Run-TryBot: Kunpei Sakai <namusyaka@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Alberto Donizetti <alb.donizetti@gmail.com>
This commit is contained in:
committed by
Alberto Donizetti
parent
d0aafc73d5
commit
ae89d30ce0
@@ -20,7 +20,7 @@ func sysctl(mib []int32, old *byte, oldlen *uintptr, new *byte, newlen uintptr)
|
||||
} else {
|
||||
p = unsafe.Pointer(&zero)
|
||||
}
|
||||
_, _, errno := syscall.Syscall6(syscall.SYS___SYSCTL, uintptr(p), uintptr(len(mib)), uintptr(unsafe.Pointer(old)), uintptr(unsafe.Pointer(oldlen)), uintptr(unsafe.Pointer(new)), uintptr(newlen))
|
||||
_, _, errno := syscall.Syscall6(syscall.SYS___SYSCTL, uintptr(p), uintptr(len(mib)), uintptr(unsafe.Pointer(old)), uintptr(unsafe.Pointer(oldlen)), uintptr(unsafe.Pointer(new)), newlen)
|
||||
if errno != 0 {
|
||||
return error(errno)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user