summaryrefslogtreecommitdiff
path: root/gcc/cp/mangle.c
diff options
context:
space:
mode:
authorgdr <gdr@138bc75d-0d04-0410-961f-82ee72b054a4>2005-12-02 11:21:28 +0000
committergdr <gdr@138bc75d-0d04-0410-961f-82ee72b054a4>2005-12-02 11:21:28 +0000
commit56e60747e9500cab0fd9829bc588fd15f4eb745a (patch)
tree02a2773c1a28cc03c9c2382a37b5628b733a02d8 /gcc/cp/mangle.c
parent4ae7f7e6c84b7bf585823a0e2d265102a6054394 (diff)
downloadgcc-56e60747e9500cab0fd9829bc588fd15f4eb745a.tar.gz
* decl2.c (get_priority_info): Use XNEW, not xmalloc.
* decl.c (push_switch): Likewise. * lex.c (handle_pragma_implementation): Likewise. * cp-objcp-common.c (decl_shadowed_for_var_insert): Use GGC_NEW, not ggc_alloc. (cxx_initialize_diagnostics): Use XNEW, not xmalloc. * class.c (init_class_processing): Use XNEWVEC, not xmalloc. * g++spec.c (lang_specific_driver): Likewise. * mangle.c (save_partially_mangled_name): Likewise. * parser.c (cp_lexer_new_main): Use GGC_NEWVEC, not ggc_alloc. (cp_parser_template_argument_list): Use XNEWVEC, nto xmalloc. (cp_parser_sizeof_operand): Likewise. * repo.c (open_repo_file, open_repo_file): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@107884 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/mangle.c')
-rw-r--r--gcc/cp/mangle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/mangle.c b/gcc/cp/mangle.c
index b07012252bb..c654d764bbd 100644
--- a/gcc/cp/mangle.c
+++ b/gcc/cp/mangle.c
@@ -276,7 +276,7 @@ save_partially_mangled_name (void)
{
gcc_assert (!partially_mangled_name);
partially_mangled_name_len = obstack_object_size (mangle_obstack);
- partially_mangled_name = xmalloc (partially_mangled_name_len);
+ partially_mangled_name = XNEWVEC (char, partially_mangled_name_len);
memcpy (partially_mangled_name, obstack_base (mangle_obstack),
partially_mangled_name_len);
obstack_free (mangle_obstack, obstack_finish (mangle_obstack));