diff options
author | Sergio Durigan Junior <sergiodj@redhat.com> | 2019-09-26 14:24:30 -0400 |
---|---|---|
committer | Sergio Durigan Junior <sergiodj@redhat.com> | 2019-09-26 14:24:30 -0400 |
commit | 50fa3001ce25e221ca2e54564b5589d29c4bed19 (patch) | |
tree | 4f99db1e48244cf2e3d86b867a90314dcf6d7777 /gdb/gdbserver/linux-low.c | |
parent | 381beca6146ac68b57edf47d28cdb335fbd11635 (diff) | |
download | fsf-binutils-gdb-50fa3001ce25e221ca2e54564b5589d29c4bed19.zip fsf-binutils-gdb-50fa3001ce25e221ca2e54564b5589d29c4bed19.tar.gz fsf-binutils-gdb-50fa3001ce25e221ca2e54564b5589d29c4bed19.tar.bz2 |
Revert "Improve ptrace-error detection on Linux targets"
This reverts commit 381beca6146ac68b57edf47d28cdb335fbd11635.
The patch hasn't been fully reviewed yet, and Pedro would like to see
more fixes.
Diffstat (limited to 'gdb/gdbserver/linux-low.c')
-rw-r--r-- | gdb/gdbserver/linux-low.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c index c0e15c1..d64c364 100644 --- a/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c @@ -967,8 +967,7 @@ linux_ptrace_fun () { if (ptrace (PTRACE_TRACEME, 0, (PTRACE_TYPE_ARG3) 0, (PTRACE_TYPE_ARG4) 0) < 0) - trace_start_error_with_name ("ptrace", - linux_ptrace_me_fail_reason (errno).c_str ()); + trace_start_error_with_name ("ptrace"); if (setpgid (0, 0) < 0) trace_start_error_with_name ("setpgid"); @@ -1166,7 +1165,7 @@ attach_proc_task_lwp_callback (ptid_t ptid) else if (err != 0) { std::string reason - = linux_ptrace_attach_fail_reason_lwp (ptid, err); + = linux_ptrace_attach_fail_reason_string (ptid, err); warning (_("Cannot attach to lwp %d: %s"), lwpid, reason.c_str ()); } @@ -1198,8 +1197,8 @@ linux_attach (unsigned long pid) { remove_process (proc); - std::string reason = linux_ptrace_attach_fail_reason (pid, err); - error (_("Cannot attach to process %ld: %s"), pid, reason.c_str ()); + std::string reason = linux_ptrace_attach_fail_reason_string (ptid, err); + error ("Cannot attach to process %ld: %s", pid, reason.c_str ()); } /* Don't ignore the initial SIGSTOP if we just attached to this |