diff options
author | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2008-10-09 04:02:35 +0000 |
---|---|---|
committer | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2008-10-09 04:02:35 +0000 |
commit | 22a60093505c0c899e50b347d0e6c86a28c16571 (patch) | |
tree | 0c68202426e4623c50601bb8b2569470eac69879 /libgfortran | |
parent | e481f79556aff354d923675e5ec885afc6cf1789 (diff) | |
download | gcc-22a60093505c0c899e50b347d0e6c86a28c16571.zip gcc-22a60093505c0c899e50b347d0e6c86a28c16571.tar.gz gcc-22a60093505c0c899e50b347d0e6c86a28c16571.tar.bz2 |
re PR libfortran/37707 (Namelist read of array of derived type incorrect)
2008-10-08 Jerry DeLisle <jvdelisle@gcc.gnu.org
PR libfortran/37707
* io/list_read.c (nml_get_obj_data): If the first namelist object rank
is greater than zero, call nml_object_read with the first object rather
than the sub-object.
From-SVN: r140995
Diffstat (limited to 'libgfortran')
-rw-r--r-- | libgfortran/ChangeLog | 7 | ||||
-rw-r--r-- | libgfortran/io/list_read.c | 3 |
2 files changed, 10 insertions, 0 deletions
diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog index 1130bdf..4e11595 100644 --- a/libgfortran/ChangeLog +++ b/libgfortran/ChangeLog @@ -1,3 +1,10 @@ +2008-10-08 Jerry DeLisle <jvdelisle@gcc.gnu.org + + PR libfortran/37707 + * io/list_read.c (nml_get_obj_data): If the first namelist object rank is + greater than zero, call nml_object_read with the first object rather + than the sub-object. + 2008-09-26 Peter O'Gorman <pogma@thewrittenword.com> Steve Ellcey <sje@cup.hp.com> diff --git a/libgfortran/io/list_read.c b/libgfortran/io/list_read.c index bcde3e1..76634a3 100644 --- a/libgfortran/io/list_read.c +++ b/libgfortran/io/list_read.c @@ -2839,6 +2839,9 @@ get_name: goto nml_err_ret; } + if (first_nl != NULL && first_nl->var_rank > 0) + nl = first_nl; + if (nml_read_obj (dtp, nl, 0, pprev_nl, nml_err_msg, nml_err_msg_size, clow, chigh) == FAILURE) goto nml_err_ret; |