Send a message to a server
int PtConnectionSend( PtConnectionClient_t *connection, unsigned long type, const void *smsg, void *rmsg, unsigned snbytes, unsigned rnbytes ); int PtConnectionSendmx( PtConnectionClient_t *connection, unsigned long type, int sparts, iov_t *siov, int rparts, iov_t *riov );
ph
The client of a connection uses these functions to send a message to the server. The server uses PtConnectionReply() and PtConnectionReplymx() to reply.
The arguments are similar to kernel functions, except that the message type isn't considered to be part of the message.
Under QNX 4, the iov_t type is a synonym for struct _mxfer_entry. The siov[0] and riov[0] entries are reserved for headers used internally by the library; the “real” message and reply buffer are defined by the contents of siov[1] through siov[sparts-1] and riov[1] through riov[rparts-1].
The number of bytes in the reply, or -1 if the send failed (errno is set).
Photon
Safety: | |
---|---|
Interrupt handler | No |
Signal handler | No |
Thread | No |
PtConnectionFlush(), PtConnectionNotify(), PtConnectionReply(), PtConnectionReplymx()
“Connections” in the Interprocess Communication chapter of the Photon Programmer's Guide