diff options
author | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-09-17 18:48:45 +0000 |
---|---|---|
committer | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-09-17 18:48:45 +0000 |
commit | add62f6afea7118bc01b8ca9dfabf1062fb65031 (patch) | |
tree | d0168824c3517b671ef6a4c4bbf09f335edd2800 /gcc/c-aux-info.c | |
parent | 10b4496ae30845cc3fd784538f35424af952ee8b (diff) | |
download | gcc-add62f6afea7118bc01b8ca9dfabf1062fb65031.tar.gz |
include:
* libiberty.h (ASTRDUP): New macro.
libiberty_optr, libiberty_nptr, libiberty_len): Declare.
libiberty:
* alloca.c (libiberty_optr, libiberty_nptr, libiberty_len):
Define.
gcc:
* c-aux-info.c (affix_data_type): Use ASTRDUP in lieu of
alloca/strcpy.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@45657 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-aux-info.c')
-rw-r--r-- | gcc/c-aux-info.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gcc/c-aux-info.c b/gcc/c-aux-info.c index ee9c5165815..c9daa1d96a1 100644 --- a/gcc/c-aux-info.c +++ b/gcc/c-aux-info.c @@ -64,13 +64,11 @@ static char * affix_data_type (param) const char *param; { - char *type_or_decl = (char *) alloca (strlen (param) + 1); + char *const type_or_decl = ASTRDUP (param); char *p = type_or_decl; char *qualifiers_then_data_type; char saved; - strcpy (type_or_decl, param); - /* Skip as many leading const's or volatile's as there are. */ for (;;) |