[Bug fortran/38122] "file already opened in another unit" error when opening /dev/null or /dev/tty twice
jvdelisle at verizon dot net
gcc-bugzilla@gcc.gnu.org
Sat Nov 15 19:15:00 GMT 2008
------- Comment #7 from jvdelisle at verizon dot net 2008-11-15 19:13 -------
Subject: Re: "file already opened in another unit" error
when opening /dev/null or /dev/tty twice
> Which OP? The originator of the c.l.f thread or the originator of
> this bug report.
Originator of this bug report. And what I am trying to say is that the NONMEM
folks could write their code so that it does not violate the standard and deals
with any need for multi-threading.
>
> As Tobias points out, attaching 2 or more unit numbers to the same
> file would open gfortran to race conditions.
Agree, don't attach 2 or more unit numbers to the same file. I have written
rudimentary multi-tasking and multi-threading code myself even when not
supported by the OS. Yes, its extra work and most system programmers would
cringe at the thought of doing that in Fortran. Respectfully, the NONMEM team
needs to fix their code.
> $0.02
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38122
More information about the Gcc-bugs
mailing list