aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbserver
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/gdbserver')
-rw-r--r--gdb/gdbserver/ChangeLog5
-rw-r--r--gdb/gdbserver/linux-mips-low.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog
index a47ef49..3fb143c 100644
--- a/gdb/gdbserver/ChangeLog
+++ b/gdb/gdbserver/ChangeLog
@@ -1,3 +1,8 @@
+2014-09-03 James Hogan <james.hogan@imgtec.com>
+
+ * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
+ to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
+
2014-09-03 Gary Benson <gbenson@redhat.com>
* linux-x86-low.c (x86_linux_prepare_to_resume): Use
diff --git a/gdb/gdbserver/linux-mips-low.c b/gdb/gdbserver/linux-mips-low.c
index 1b2160b..377284b 100644
--- a/gdb/gdbserver/linux-mips-low.c
+++ b/gdb/gdbserver/linux-mips-low.c
@@ -128,6 +128,7 @@ mips_read_description (void)
{
int pid = lwpid_of (current_inferior);
+ errno = 0;
ptrace (PTRACE_PEEKUSER, pid, DSP_CONTROL, 0);
switch (errno)
{