Look for scatter/gather buffering.
In particular, see:  man sendmsg and the declarations of struct msghdr,
struct iovec.

On Tue, 18 Jun 2002, Iftach Hyams wrote:

>  When writing a porotocol based on UDP/IP, a header is needed. This cause a
> duplicate copy
> of the data :
> ...
> (user code)
> sendBuffer (struct prot-address addr, void* pnt, int length);
> ....
>
> My code :
> struct sendDataType sendData;
> memcpy (*sendData.data, pnt, length);
> sendData.header = bla bla;
> sendto (s, &sendData, sizeof (sendData), 0, addressee, addresseeLengh);
>
> - Is there alternative interface ? (A portable & standart interface will be
> better)
> - Should I use raw sockets ?

                                             --- Omer
There is no IGLU Cabal.  A moment ago, we - The Men In Black - made you
forget about its existence.
WARNING TO SPAMMERS:  at http://www.zak.co.il/spamwarning.html


=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]

Reply via email to