http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30162
Hristo Iliev <iliev at rz dot rwth-aachen.de> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |iliev at rz dot
| |rwth-aachen.de
--- Comment #22 from Hristo Iliev <iliev at rz dot rwth-aachen.de> 2012-08-02
17:34:03 UTC ---
Revision 180701 removed all checks for special files in unit.c:unit_truncate().
As a consequence programs compiled with gfortran 4.6.3 and newer cannot to
write (formatted) to Unix named pipes as ftruncate() fails with EINVAL:
(64-bit code)
lseek(3, 0, SEEK_CUR) = -1 ESPIPE (Illegal seek)
write(3, " Hello, world!\n", 15) = 15
lseek(3, 0, SEEK_CUR) = -1 ESPIPE (Illegal seek)
ftruncate(3, 18446744073709551615) = -1 EINVAL (Invalid argument)
(32-bit code)
_llseek(3, 0, 0xffba8fa0, SEEK_CUR) = -1 ESPIPE (Illegal seek)
write(3, " Hello, world!\n", 15) = 15
_llseek(3, 0, 0xffba9080, SEEK_CUR) = -1 ESPIPE (Illegal seek)
ftruncate64(3, 18446744073709551615) = -1 EINVAL (Invalid argument)