Remove some unnecessary declarations and configury
configure checks for declarations of free, malloc, and realloc; but the results are only used in a single spot: utils.c. I think these checks are long since obsolete, so this patch removes them. Grepping the entire tree for these HAVE_DECL_ symbols, the only uses of possible interest to gdb come from bfd/sysdep.h; but this is not (nor should be) included by gdb. (And furthermore I think the code there is probably also obsolete.) gdb/ChangeLog 2018-07-24 Tom Tromey <tom@tromey.com> * utils.c (malloc, realloc, free): Don't declare. * configure, config.in: Rebuild. * configure.ac: Don't check for declarations of free, malloc, or realloc.
This commit is contained in:
parent
56522fc5af
commit
29d17e4773
5 changed files with 8 additions and 53 deletions
10
gdb/utils.c
10
gdb/utils.c
|
@ -72,16 +72,6 @@
|
|||
#include <algorithm>
|
||||
#include "common/pathstuff.h"
|
||||
|
||||
#if !HAVE_DECL_MALLOC
|
||||
extern PTR malloc (); /* ARI: PTR */
|
||||
#endif
|
||||
#if !HAVE_DECL_REALLOC
|
||||
extern PTR realloc (); /* ARI: PTR */
|
||||
#endif
|
||||
#if !HAVE_DECL_FREE
|
||||
extern void free ();
|
||||
#endif
|
||||
|
||||
void (*deprecated_error_begin_hook) (void);
|
||||
|
||||
/* Prototypes for local functions */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue