* mn10300-tdep.c (mn10300_dwarf2_reg_to_regnum): Use ARRAY_SIZE.
authorKevin Buettner <kevinb@redhat.com>
Sat, 3 Sep 2005 01:45:30 +0000 (01:45 +0000)
committerKevin Buettner <kevinb@redhat.com>
Sat, 3 Sep 2005 01:45:30 +0000 (01:45 +0000)
Change internal error to warning.  Add i18n markup to warning
string.

gdb/ChangeLog
gdb/mn10300-tdep.c

index 3508c498c08a8eeb78d0603d394c182f79a8fd20..c791019c21d9675c9cfe2912fdd2674aef1f3c34 100644 (file)
@@ -1,3 +1,9 @@
+2005-09-02  Kevin Buettner  <kevinb@redhat.com>
+
+       * mn10300-tdep.c (mn10300_dwarf2_reg_to_regnum): Use ARRAY_SIZE.
+       Change internal error to warning.  Add i18n markup to warning
+       string.
+       
 2005-09-02  Kevin Buettner  <kevinb@redhat.com>
 
        * mn10300-tdep.c (mn10300_dwarf2_reg_to_regnum): New function.
index db9953b31aa6615ced6f0200bce99d2311ebf13c..532015d4049d5d9feb30bc3611984a39ab14ddb4 100644 (file)
@@ -961,10 +961,9 @@ mn10300_dwarf2_reg_to_regnum (int dwarf2)
   };
 
   if (dwarf2 < 0
-      || dwarf2 >= (sizeof (dwarf2_to_gdb) / sizeof (dwarf2_to_gdb[0]))
+      || dwarf2 >= ARRAY_SIZE (dwarf2_to_gdb)
       || dwarf2_to_gdb[dwarf2] == -1)
-    internal_error (__FILE__, __LINE__,
-                    "bogus register number in debug info: %d", dwarf2);
+    warning (_("bogus register number in debug info: %d"), dwarf2);
 
   return dwarf2_to_gdb[dwarf2];
 }