From 83437e6709a57a4a8552e4a6a4b5b94b1ff34d82 Mon Sep 17 00:00:00 2001 From: Jerry DeLisle Date: Sun, 31 Mar 2013 20:32:33 +0000 Subject: re PR libfortran/56786 (Namelist read fails with designators containing embedded spaces) 2013-03-31 Jerry DeLisle PR libfortran/56786 * io/list_read.c (nml_parse_qualifier): Remove spurious next_char call when checking for EOF. Use error return mechanism when EOF detected. Do not return false unless parse_err_msg and parse_err_msg_size have been set. Use hit_eof. (nml_get_obj_data): Likewise use the correct error mechanism. * io/transfer.c (hit_eof): Do not set AFTER_ENDFILE if in namelist mode. From-SVN: r197290 --- libgfortran/io/transfer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libgfortran/io/transfer.c') diff --git a/libgfortran/io/transfer.c b/libgfortran/io/transfer.c index 6fa954c..bb93009 100644 --- a/libgfortran/io/transfer.c +++ b/libgfortran/io/transfer.c @@ -3840,7 +3840,7 @@ hit_eof (st_parameter_dt * dtp) case NO_ENDFILE: case AT_ENDFILE: generate_error (&dtp->common, LIBERROR_END, NULL); - if (!is_internal_unit (dtp)) + if (!is_internal_unit (dtp) && !dtp->u.p.namelist_mode) { dtp->u.p.current_unit->endfile = AFTER_ENDFILE; dtp->u.p.current_unit->current_record = 0; -- cgit v1.1