use XNEW and related macros more
[deliverable/binutils-gdb.git] / gas / config / tc-sh.c
index 3390a409585bdb7b67dff75e657ce4c61c26196e..b15acf8e8d37503e6f27033e18e8ce3500ed95bb 100644 (file)
@@ -4424,8 +4424,8 @@ tc_gen_reloc (asection *section ATTRIBUTE_UNUSED, fixS *fixp)
   arelent *rel;
   bfd_reloc_code_real_type r_type;
 
-  rel = (arelent *) xmalloc (sizeof (arelent));
-  rel->sym_ptr_ptr = (asymbol **) xmalloc (sizeof (asymbol *));
+  rel = XNEW (arelent);
+  rel->sym_ptr_ptr = XNEW (asymbol *);
   *rel->sym_ptr_ptr = symbol_get_bfdsym (fixp->fx_addsy);
   rel->address = fixp->fx_frag->fr_address + fixp->fx_where;
 
This page took 0.02363 seconds and 4 git commands to generate.