From 0573fa421a606a6c76468c8bcd813e02f71283d1 Mon Sep 17 00:00:00 2001 From: Kaz Kojima Date: Mon, 16 Oct 2006 21:22:04 +0900 Subject: [PATCH] io.c (gfc_match_close): Ensure that status is terminated by a NULL element. * io.c (gfc_match_close): Ensure that status is terminated by a NULL element. From-SVN: r117785 --- gcc/fortran/ChangeLog | 5 +++++ gcc/fortran/io.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 6d7e4c42b2f..a86d161c776 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2006-10-16 Kaz Kojima + + * io.c (gfc_match_close): Ensure that status is terminated by + a NULL element. + 2006-10-16 Tobias Burnus * trans-stmt.c: Fix a typo diff --git a/gcc/fortran/io.c b/gcc/fortran/io.c index b0dfa8f0311..d4897694bbd 100644 --- a/gcc/fortran/io.c +++ b/gcc/fortran/io.c @@ -1745,7 +1745,7 @@ gfc_match_close (void) /* Checks on the STATUS specifier. */ if (close->status && close->status->expr_type == EXPR_CONSTANT) { - static const char * status[] = { "KEEP", "DELETE" }; + static const char * status[] = { "KEEP", "DELETE", NULL }; if (!compare_to_allowed_values ("STATUS", status, NULL, NULL, close->status->value.character.string,