]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: re PR fortran/58324 (Bogus END-of-line error with list-directed I/O of...
authorJerry DeLisle <jvdelisle@gcc.gnu.org>
Sat, 15 Mar 2014 20:34:58 +0000 (20:34 +0000)
committerJerry DeLisle <jvdelisle@gcc.gnu.org>
Sat, 15 Mar 2014 20:34:58 +0000 (20:34 +0000)
2014-03-15  Jerry DeLisle  <jvdelisle@gcc.gnu>

Backport from mainline
PR libfortran/58324
* gfortran.dg/list_read_12.f90: New test.

From-SVN: r208596

gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/list_read_12.f90 [new file with mode: 0644]

index a736c0791018a2060c7bbaced8f89cdd7cd67949..65b12200ed668c5e11a7b1e6a02e00939da01ef3 100644 (file)
@@ -1,3 +1,9 @@
+2014-03-15  Jerry DeLisle  <jvdelisle@gcc.gnu>
+
+       Backport from mainline
+       PR libfortran/58324
+       * gfortran.dg/list_read_12.f90: New test.
+
 2014-03-13  Joey Ye  <joey.ye@arm.com>
 
        Backport from mainline
diff --git a/gcc/testsuite/gfortran.dg/list_read_12.f90 b/gcc/testsuite/gfortran.dg/list_read_12.f90
new file mode 100644 (file)
index 0000000..811ef15
--- /dev/null
@@ -0,0 +1,11 @@
+! { dg-do run }
+! PR58324 Bogus end of file condition
+integer :: i, ios
+open(99, access='stream', form='unformatted')
+write(99) "5 a"
+close(99)
+
+open(99, access='sequential', form='formatted')
+read(99, *, iostat=ios) i
+if (ios /= 0) call abort
+end