summaryrefslogtreecommitdiff
path: root/gcc/toplev.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r--gcc/toplev.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c
index e1b97a104ff..eadcb36958f 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -2166,11 +2166,17 @@ pop_srcloc ()
input_file_stack = fs->next;
free (fs);
input_file_stack_tick++;
- /* The initial source file is never popped. */
- if (!input_file_stack)
- abort ();
- input_filename = input_file_stack->name;
- lineno = input_file_stack->line;
+
+ if (input_file_stack)
+ {
+ input_filename = input_file_stack->name;
+ lineno = input_file_stack->line;
+ }
+ else
+ {
+ input_filename = NULL;
+ lineno = 0;
+ }
}
/* Compile an entire translation unit. Write a file of assembly