This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Infinite loop with -include and -M


When preprocessing a file with -M (or any other option that sets
flag_no_output) and there is a -include file the preprocessor enters
an infinite loop in preprocess_file because pfile->buffer->prev never
becomes NULL, and eventually the process runs out of memory.

$ echo > included.c
$ echo > included.h
$ gcc -include included.h -M included.c

Andreas.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]