2001-12-20 Elena Zannoni <ezannoni@redhat.com>
authorElena Zannoni <ezannoni@kwikemart.cygnus.com>
Thu, 20 Dec 2001 23:29:24 +0000 (23:29 +0000)
committerElena Zannoni <ezannoni@kwikemart.cygnus.com>
Thu, 20 Dec 2001 23:29:24 +0000 (23:29 +0000)
        * rs6000-nat.c (fetch_register): Don't error out unless the
        register number is really bogus.

gdb/ChangeLog
gdb/rs6000-nat.c

index 2be4f288d13643bd8b83a626cdf379b4b730d0bc..c796c70fd095f08fc75716ab03f56fbf3dfe03c9 100644 (file)
@@ -1,3 +1,8 @@
+2001-12-20  Elena Zannoni  <ezannoni@redhat.com>
+
+        * rs6000-nat.c (fetch_register): Don't error out unless the
+        register number is really bogus.
+
 2001-12-20  Michael Snyder  <msnyder@redhat.com>
 
        * maint.c (maintenance_info_sections): Accept new argument
index 1f2e1f7cfda1af60cd12d065e0c4313bcd804603..12229cddc0e4047ab4c1fdd562084531f8004014 100644 (file)
@@ -206,9 +206,12 @@ fetch_register (int regno)
 
   /* Bogus register number. */
   else if (regno > LAST_UISA_SP_REGNUM)
-    fprintf_unfiltered (gdb_stderr,
-                       "gdb error: register no %d not implemented.\n",
-                       regno);
+    {
+      if (regno >= NUM_REGS)
+       fprintf_unfiltered (gdb_stderr,
+                           "gdb error: register no %d not implemented.\n",
+                           regno);
+    }
 
   /* Fixed-point registers. */
   else