Re: recvmsg() in Tiger
Re: recvmsg() in Tiger
- Subject: Re: recvmsg() in Tiger
- From: Alastair Houghton <email@hidden>
- Date: Fri, 13 May 2005 10:38:58 +0100
On 13 May 2005, at 10:02, Gerriet M. Denkmann wrote:
I was using recvmsg() on a pipe in Panther. Tiger tells me that a
pipe is not a socket, which is correct.
The advice I got (thanks to all who replied) was: either use a
normal read() with a pipe or use real sockets with recvmsg().
Well, kind of obvious (I had hoped for some Tiger magic to turn a
pipe into a socket).
:-)
I guess I will have to use sockets, but I do not know how to create
one, and secondly, how to redirect stdout to the socket.
Maybe a kind soul will have an insight and some mercy.
Just replace your call to pipe() with something like
int pipefds[2];
int ret = socketpair (AF_UNIX, SOCK_STREAM, 0, pipefds);
After which, it's the same as using a pipe.
Kind regards,
Alastair.
--
http://www.alastairs-place.net
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden