diff options
author | Franz Sirl <Franz.Sirl-kernel@lauterbach.com> | 2001-01-03 22:26:05 +0000 |
---|---|---|
committer | Franz Sirl <sirl@gcc.gnu.org> | 2001-01-03 22:26:05 +0000 |
commit | fa5db8286c9eeb7f937ebc52899aa741061efee2 (patch) | |
tree | 6bcd78c60d57778bf8daea2542acbe9b0f186035 /gcc | |
parent | 975d393ab8c7dc0527586d34881837924cbb0026 (diff) | |
download | gcc-fa5db8286c9eeb7f937ebc52899aa741061efee2.zip gcc-fa5db8286c9eeb7f937ebc52899aa741061efee2.tar.gz gcc-fa5db8286c9eeb7f937ebc52899aa741061efee2.tar.bz2 |
tradcpp.c (main): Make sure finclude() is called with a valid indepth value while handling -include.
2001-01-03 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
* tradcpp.c (main): Make sure finclude() is called with a valid
indepth value while handling -include.
From-SVN: r38674
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/tradcpp.c | 4 |
2 files changed, 8 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7c91711..3446f71 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2001-01-03 Franz Sirl <Franz.Sirl-kernel@lauterbach.com> + + * tradcpp.c (main): Make sure finclude() is called with a valid + indepth value while handling -include. + 2001-01-03 Alexandre Oliva <aoliva@redhat.com> * gencodes.c (output_predicate_decls): New function. diff --git a/gcc/tradcpp.c b/gcc/tradcpp.c index bb97249..206541c 100644 --- a/gcc/tradcpp.c +++ b/gcc/tradcpp.c @@ -1,5 +1,5 @@ /* C Compatible Compiler Preprocessor (CCCP) -Copyright (C) 1986, 1987, 1989, 2000 Free Software Foundation, Inc. +Copyright (C) 1986, 1987, 1989, 2000, 2001 Free Software Foundation, Inc. Written by Paul Rubin, June 1986 Adapted to ANSI C, Richard Stallman, Jan 1987 Dusted off, polished, and adapted for use as traditional @@ -768,6 +768,7 @@ main (argc, argv) so that only their macro definitions matter. */ no_output++; + indepth++; for (i = 1; i < argc; i++) if (pend[i].type == PD_FILE) { @@ -779,6 +780,7 @@ main (argc, argv) } finclude (fd, pend[i].arg, &outbuf); } + indepth--; no_output--; /* Pending directives no longer needed. */ |