------- Comment #1 from fxcoudert at gcc dot gnu dot org 2007-04-17 14:03 ------- It also fails with non-preconnected unit, if the unit is opened outside the parallel region:
$ cat hello.f90 integer :: tid open (10, file="foo") !$omp parallel private(tid) tid = 0 if (tid .eq. 0) write(10,*) 'hello' !$omp end parallel end $ gfortran -fopenmp hello.f90 -g -static && ./a.out zsh: segmentation fault ./a.out -- fxcoudert at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2007-04-17 14:03:13 date| | Summary|Segfault at runtime on I/O |Segfault at runtime on I/O |to preconnected unit with |with OpenMP and static |OpenMP |linking http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31604