summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/binutils
diff options
context:
space:
mode:
authorPer Fogelstrom <pefo@cvs.openbsd.org>1999-06-01 17:56:02 +0000
committerPer Fogelstrom <pefo@cvs.openbsd.org>1999-06-01 17:56:02 +0000
commit108deae6ab5c936b3526acb56d0ed44dbe48402b (patch)
tree48a111d87d1b202a9846d8dcf7252169a0fc7879 /gnu/usr.bin/binutils
parent4250454a54849b9eebc218dc55bb385295511485 (diff)
Make gdb on mips understand corefile contents
Diffstat (limited to 'gnu/usr.bin/binutils')
-rw-r--r--gnu/usr.bin/binutils/gdb/mips-obsd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gnu/usr.bin/binutils/gdb/mips-obsd.c b/gnu/usr.bin/binutils/gdb/mips-obsd.c
index c669979ec8c..aced72e78fb 100644
--- a/gnu/usr.bin/binutils/gdb/mips-obsd.c
+++ b/gnu/usr.bin/binutils/gdb/mips-obsd.c
@@ -63,6 +63,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
: regno >= FP0_REGNUM ? FPBASE + (regno - FP0_REGNUM) \
: 0)
+#define MIPS_NUM_REGS (FSR + 1)
+
static char zerobuf[MAX_REGISTER_RAW_SIZE] = {0};
/* Get all registers from the inferior */
@@ -161,7 +163,7 @@ fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
int bad_reg = -1;
register reg_ptr = -reg_addr; /* Original u.u_ar0 is -reg_addr. */
- for (regno = 0; regno < NUM_REGS; regno++)
+ for (regno = 0; regno < MIPS_NUM_REGS; regno++)
{
addr = (regno * sizeof(int) + reg_ptr);
if (addr >= core_reg_size) {