diff options
Diffstat (limited to 'gcc/input.c')
-rw-r--r-- | gcc/input.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/gcc/input.c b/gcc/input.c index 290680c1e5a..547c177b09f 100644 --- a/gcc/input.c +++ b/gcc/input.c @@ -293,11 +293,8 @@ add_file_to_cache_tab (const char *file_path) { FILE *fp = fopen (file_path, "r"); - if (ferror (fp)) - { - fclose (fp); - return NULL; - } + if (fp == NULL) + return NULL; unsigned highest_use_count = 0; fcache *r = evicted_cache_tab_entry (&highest_use_count); |