delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1998/07/13/17:39:38

From: setera AT us DOT ibm DOT com (Craig Setera)
Subject: Unable to fdopen() a pipe handle
13 Jul 1998 17:39:38 -0700 :
Message-ID: <5010400024885002000002L022*.cygnus.gnu-win32@MHS>
Mime-Version: 1.0
To: <gnu-win32 AT cygnus DOT com>

I've got a chunk of code that create an anonymous pipe using pipe() and then
attempts to create a write stream on the pipe using fdopen() (something like
this... from memory... not necessarily correct):

int mypipe[2];
FILE *mystream;

pipe(mypipe);
mystream = fdopen(mypipe[1], "w");

I can't seem to get fdopen() to return anything other than NULL.  Any thoughts?

Craig


Craig Setera
AS/400 Enterprise Java Development
IBM Rochester
setera AT us DOT ibm DOT com
(507) 253-3387 - Tie: 553-3387
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019