s/abort/gdb_assert/
authorAndrew Cagney <cagney@redhat.com>
Thu, 7 Jun 2001 14:51:20 +0000 (14:51 +0000)
committerAndrew Cagney <cagney@redhat.com>
Thu, 7 Jun 2001 14:51:20 +0000 (14:51 +0000)
gdb/ChangeLog
gdb/gnu-v3-abi.c

index cdaba47..0f27a90 100644 (file)
@@ -1,3 +1,8 @@
+2001-06-07  Andrew Cagney  <ac131313@redhat.com>
+
+       * gnu-v3-abi.c: Include "gdb_assert.h".
+       (build_gdb_vtable_type): Replace abort() with gdb_assert().
+
 2001-06-06  Jim Blandy  <jimb@redhat.com>
 
        * cp-abi.h: Rearrange code to put documentation comments above the
index 015bead..d9da17c 100644 (file)
@@ -23,6 +23,7 @@
 #include "value.h"
 #include "cp-abi.h"
 #include "demangle.h"
+#include "gdb_assert.h"
 
 static struct cp_abi_ops gnu_v3_abi_ops;
 
@@ -156,8 +157,7 @@ build_gdb_vtable_type (struct gdbarch *arch)
   field++;
 
   /* We assumed in the allocation above that there were four fields.  */
-  if (field != field_list + 4)
-    abort ();
+  gdb_assert (field == (field_list + 4));
 
   t = init_type (TYPE_CODE_STRUCT, offset, 0, 0, 0);
   TYPE_NFIELDS (t) = field - field_list;