From: Michael Snyder Date: Tue, 1 Mar 2011 23:07:40 +0000 (+0000) Subject: 2011-03-01 Michael Snyder X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=dc19db01c117e015c4656cfb4aa78bb9acaf8ba8;p=binutils-gdb.git 2011-03-01 Michael Snyder * ada-lang.c (ada_make_symbol_completion_list): Replace malloc with xmalloc. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5be6deaeed7..9259a5ede41 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,8 @@ 2011-03-01 Michael Snyder + * ada-lang.c (ada_make_symbol_completion_list): Replace malloc + with xmalloc. + * ada-lang.c (aggregate_assign_others): Rename inner scope variable which shadows function parameter. diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 55b05f102e5..d0a10146dd6 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -5634,7 +5634,7 @@ ada_make_symbol_completion_list (char *text0, char *word) { const size_t completions_size = VEC_length (char_ptr, completions) * sizeof (char *); - char **result = malloc (completions_size); + char **result = xmalloc (completions_size); memcpy (result, VEC_address (char_ptr, completions), completions_size);