1
0
mirror of https://github.com/golang/go synced 2024-10-03 14:11:21 -06:00

Return ptrace event message when there's no error instead of

only when there's an error.

R=rsc
APPROVED=rsc
DELTA=3  (0 added, 2 deleted, 1 changed)
OCL=31650
CL=31650
This commit is contained in:
Austin Clements 2009-07-14 18:05:29 -07:00
parent ba9d697336
commit b6e6663946

View File

@ -521,9 +521,7 @@ func PtraceSetOptions(pid int, options int) (errno int) {
func PtraceGetEventMsg(pid int) (msg uint, errno int) { func PtraceGetEventMsg(pid int) (msg uint, errno int) {
var data _C_long; var data _C_long;
errno = ptrace(_PTRACE_GETEVENTMSG, pid, 0, uintptr(unsafe.Pointer(&data))); errno = ptrace(_PTRACE_GETEVENTMSG, pid, 0, uintptr(unsafe.Pointer(&data)));
if errno != 0 {
msg = uint(data); msg = uint(data);
}
return; return;
} }