* mips-tdep.c (mips_register_name): Fix fencepost error involving
authorKevin Buettner <kevinb@redhat.com>
Wed, 19 Mar 2003 06:49:17 +0000 (06:49 +0000)
committerKevin Buettner <kevinb@redhat.com>
Wed, 19 Mar 2003 06:49:17 +0000 (06:49 +0000)
NUM_REGS bounds check.

gdb/ChangeLog
gdb/mips-tdep.c

index 31c7b301782185bc0d665d371ef6269a860037d5..3868d38e8e8f525cc7fb679ac764c373dbf09d65 100644 (file)
@@ -1,3 +1,8 @@
+2003-03-18  Kevin Buettner  <kevinb@redhat.com>
+
+       * mips-tdep.c (mips_register_name): Fix fencepost error involving
+       NUM_REGS bounds check.
+
 2003-03-18  Kevin Buettner  <kevinb@redhat.com>
 
        * Makefile.in (mips-tdep.o): Add dependency on $(gdb_assert_h).
index a011728fef9a5487e2042e723e45bfffae543849..d91af12499335b4c2ac474b0696c3c0a4f76864c 100644 (file)
@@ -402,7 +402,7 @@ mips_register_name (int regno)
       else
        return mips_gpr_names[regno];
     }
-  else if (32 <= regno && regno <= NUM_REGS)
+  else if (32 <= regno && regno < NUM_REGS)
     return mips_processor_reg_names[regno - 32];
   else
     internal_error (__FILE__, __LINE__,