I built a test case fron your code snippet which runs fine on my SL5 install with supplied g77 from the 'compat' package. Here's the code: real*8 x,erg, x1(126), set1(126) nmax1=126 cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc open(unit=1, $ file='RW-total-tadmix4pi-6pi-DY.dat') do x=0.2d0,1.45d0,0.01d0 erg = x * 2.0 write(unit=1,fmt='(2g25.8e3)') $ x,erg end do close(unit=1) cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc c add omega and phi (all pT) open (unit=2, file='RW-total-tadmix4pi-6pi-DY.dat', $ status='old') do j=1,nmax1 read(unit=2,fmt='(2g25.8e3)') x1(j),set1(j) write(*,*) x1(j),set1(j) end do close(unit=2) cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc stop end The only change in your snippet is the computation of erg which shouln't be pertinent to the problem. Make sure you have all the required 'compat' packages installed. Is compat-libf2c-34-3.4.6-4 installed? Tony Hendrik van Hees wrote: > Thank you very much for all the responses. I think I didn't make the > problem clear. With the older version of gcc (I am using the fortran > compiler, g77) > > gcc version 3.3.5 20050117 (prerelease) (SUSE Linux) > > the little code runs fine. > > With the newer version, which is definitely in my installation of SL 5 > (I use yum as a package manager), > > gcc version 3.4.6 20060404 (Red Hat 3.4.6-4) > > the same code does not work any more. Perhaps it helps, when I give the > relevant piece of code: