re PR libfortran/25550 (file data corrupted after reading end of file)
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25550 * gfortran.dg/endfile.f: New test. From-SVN: r109102
This commit is contained in:
parent
b5918dea9c
commit
6c8ccf1c5a
@ -1,3 +1,8 @@
|
|||||||
|
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
|
||||||
|
|
||||||
|
PR libgfortran/25550
|
||||||
|
* gfortran.dg/endfile.f: New test.
|
||||||
|
|
||||||
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
|
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
|
||||||
|
|
||||||
PR libgfortran/25419
|
PR libgfortran/25419
|
||||||
|
18
gcc/testsuite/gfortran.dg/endfile.f
Normal file
18
gcc/testsuite/gfortran.dg/endfile.f
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
! { dg-do run }
|
||||||
|
! PR25550 file data corrupted after reading end of file.
|
||||||
|
! Derived from example given in PR from Dale Ranta.
|
||||||
|
! Contributed by Jerry DeLisle <jvdelisle@gcc.gnu.org>
|
||||||
|
integer data
|
||||||
|
data=-1
|
||||||
|
open(unit=11,status='scratch',form='unformatted')
|
||||||
|
write(11)data
|
||||||
|
read(11,end=1000 )data
|
||||||
|
call abort()
|
||||||
|
1000 continue
|
||||||
|
rewind (11)
|
||||||
|
read(11)data
|
||||||
|
1001 continue
|
||||||
|
if(data.ne.-1) call abort
|
||||||
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user