man3tcp/SendRec

Table of Contents

Name

SendRec - send a TRANS record

Description

SendRec xdr encapsulates a TRANS record and writes it to a socket.

SetSendRecTMO sets the timeout value for transmission for all sockets in an application. If the write() on the socket blocks longer than the timeout value the write is terminated and the socket is marked as invalid for further I/O. Usually SetSendRecTMO() is called once at initialization.

This function is part of libtcp.

Syntax

void SetSendRecTMO(
   int timeval

   );

int SendRec(
   int fo,

   TRANS *Tr,

   char *Cname,

   int verbosity

   );

Arguments

timeval

TMO value in seconds. This is a global parameter which applies to all sockets in the application.

fo

socket file descriptor.

Tr

pointer to a TRANS record

Cname

A string containing the name of the program or function which called SendRec. This can be useful for debugging purposes to identify the caller of SendRec.

verbosity

0 - suppress all messages
1 - suppress "invalid I/O" messages, print all others
2 - print all messages

Notes

"invalid I/O" messages occur if SendRec() is called after a file descriptor is placed on the invalid list. In many cases this can happen as part of normal I/O bacause there may be several SendRec() calls before dead connection occurs.

See Also

libtcp(3tcp)

Manual page revision

$Id: SendRec.3,v 1.3 2008/08/22 18:29:21 kitchen Exp $


Table of Contents