[Bug libfortran/25697] libfortran - Segmentation fault/ Bad Address on unformatted read
dir at lanl dot gov
gcc-bugzilla@gcc.gnu.org
Wed Jan 11 16:02:00 GMT 2006
------- Comment #9 from dir at lanl dot gov 2006-01-11 16:02 -------
With a larger amount of data it only takes one write -
[dranta:~/tests/gfortran-D] dir% gfortran -o write22 write22.f
[dranta:~/tests/gfortran-D] dir% write22
Bus error
[dranta:~/tests/gfortran-D] dir% cat write22.f
integer data(10000)
do i = 1,10000
data(i)=-1
enddo
open(unit=11,status='scratch',form='unformatted')
data(1)=1
data(10000)=-1
write(11)data
read(11,end= 1000 )data
call abort()
1000 continue
backspace 11
backspace 11
read(11,end= 1001 )data
if(data(1).ne. 1.or.data(10000).ne. -1)then
call abort()
endif
1001 continue
read(11,end= 1002 )data
call abort()
1002 continue
close(11)
end
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25697
More information about the Gcc-bugs
mailing list