aboutsummaryrefslogtreecommitdiff
path: root/gdb/jv-lang.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/jv-lang.c')
-rw-r--r--gdb/jv-lang.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/gdb/jv-lang.c b/gdb/jv-lang.c
index 285aa06..1bd8624 100644
--- a/gdb/jv-lang.c
+++ b/gdb/jv-lang.c
@@ -185,9 +185,7 @@ add_class_symbol (struct type *type, CORE_ADDR addr)
struct symbol *sym;
struct objfile *objfile = get_dynamics_objfile (get_type_arch (type));
- sym = (struct symbol *)
- obstack_alloc (&objfile->objfile_obstack, sizeof (struct symbol));
- memset (sym, 0, sizeof (struct symbol));
+ sym = allocate_symbol (objfile);
SYMBOL_SET_LANGUAGE (sym, language_java);
SYMBOL_SET_LINKAGE_NAME (sym, TYPE_TAG_NAME (type));
SYMBOL_ACLASS_INDEX (sym) = LOC_TYPEDEF;