This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libfortran/30162] [4.7/4.8 Regression] I/O with named pipes does not work
- From: "tkoenig at netcologne dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 22 Dec 2012 20:16:07 +0000
- Subject: [Bug libfortran/30162] [4.7/4.8 Regression] I/O with named pipes does not work
- Auto-submitted: auto-generated
- References: <bug-30162-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30162
--- Comment #37 from tkoenig at netcologne dot de <tkoenig at netcologne dot de> 2012-12-22 20:16:07 UTC ---
Hi Dominique,
> The best I can do (without understanding it) is
>
> (1) if I use dtruss (should be equivalent to strace) on a, I get
>
> [macbook] f90/bug% 25210/0x2baef9e: lseek(0x3, 0x0, 0x1) = -1 Err#29
> 25210/0x2baef9e: lseek(0x3, 0xFFFFFFFFFFFFFFF4, 0x1) = -1 Err#29
>
> (2) if I use it on b, I get
>
> [macbook] f90/bug% 25218/0x2baf031: lseek(0x3, 0x0, 0x1) = -1 Err#29
> 25218/0x2baf031: lseek(0x3, 0x4, 0x1) = -1 Err#29
That doesn't point to anything suspicious.
Can you tell me what happens if you apply this patch?
Index: io/unix.c
===================================================================
--- io/unix.c (Revision 194679)
+++ io/unix.c (Arbeitskopie)
@@ -349,7 +349,7 @@
/* Non-seekable files should always be assumed to be at
current position. */
- if (x == -1 && errno == ESPIPE)
+ if (x == -1)
x = 0;
return x;