vendor/golang.org/x/sys/unix/syscall_freebsd_amd64.go
changeset 260 445e01aede7e
parent 256 6d9efbef00a9
child 262 8d3354485fc3
equal deleted inserted replaced
259:db4911b0c721 260:445e01aede7e
    55 }
    55 }
    56 
    56 
    57 func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
    57 func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
    58 
    58 
    59 func PtraceGetFsBase(pid int, fsbase *int64) (err error) {
    59 func PtraceGetFsBase(pid int, fsbase *int64) (err error) {
    60 	return ptrace(PTRACE_GETFSBASE, pid, uintptr(unsafe.Pointer(fsbase)), 0)
    60 	return ptrace(PT_GETFSBASE, pid, uintptr(unsafe.Pointer(fsbase)), 0)
    61 }
    61 }
    62 
    62 
    63 func PtraceIO(req int, pid int, addr uintptr, out []byte, countin int) (count int, err error) {
    63 func PtraceIO(req int, pid int, addr uintptr, out []byte, countin int) (count int, err error) {
    64 	ioDesc := PtraceIoDesc{Op: int32(req), Offs: (*byte)(unsafe.Pointer(addr)), Addr: (*byte)(unsafe.Pointer(&out[0])), Len: uint64(countin)}
    64 	ioDesc := PtraceIoDesc{Op: int32(req), Offs: (*byte)(unsafe.Pointer(addr)), Addr: (*byte)(unsafe.Pointer(&out[0])), Len: uint64(countin)}
    65 	err = ptrace(PTRACE_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
    65 	err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
    66 	return int(ioDesc.Len), err
    66 	return int(ioDesc.Len), err
    67 }
    67 }