diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1997-03-19 17:19:27 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1997-03-19 17:19:27 -0500 |
commit | 52320a474f6819a407e2be7321551fff49879755 (patch) | |
tree | c9f79c87dffb86895ebd93cfdeafc929dc6b5e06 /gcc/cpplib.c | |
parent | 982ce905794acff67d945df711e476799b0652f9 (diff) | |
download | gcc-52320a474f6819a407e2be7321551fff49879755.zip gcc-52320a474f6819a407e2be7321551fff49879755.tar.gz gcc-52320a474f6819a407e2be7321551fff49879755.tar.bz2 |
(do_error, do_warning): Fix memory leak.
From-SVN: r13752
Diffstat (limited to 'gcc/cpplib.c')
-rw-r--r-- | gcc/cpplib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/cpplib.c b/gcc/cpplib.c index 92820da..f7e43ff 100644 --- a/gcc/cpplib.c +++ b/gcc/cpplib.c @@ -3880,7 +3880,7 @@ do_error (pfile, keyword, buf, limit) U_CHAR *buf, *limit; { int length = limit - buf; - U_CHAR *copy = (U_CHAR *) xmalloc (length + 1); + U_CHAR *copy = (U_CHAR *) alloca (length + 1); bcopy (buf, copy, length); copy[length] = 0; SKIP_WHITE_SPACE (copy); @@ -3901,7 +3901,7 @@ do_warning (pfile, keyword, buf, limit) U_CHAR *buf, *limit; { int length = limit - buf; - U_CHAR *copy = (U_CHAR *) xmalloc (length + 1); + U_CHAR *copy = (U_CHAR *) alloca (length + 1); bcopy (buf, copy, length); copy[length] = 0; SKIP_WHITE_SPACE (copy); |