![]() |
|
| << Previous | Index | Next >> | |
| | |
int tcp_extopen( tcp_Socket *s, int iface, word lport,
longword remip, word port, dataHandler_t datahandler,
long buffer, int buflen );Description
Actively creates a session with another machine. The
bufferandbuflenparameters allow a user to supply a socket buffer, instead of using a socket buffer from the pool.tcp_extopen()is an extended version oftcp_open().
s
- Pointer to socket's data structure.
iface
- Local interface on which to open the socket. Use
IF_ANYif interface is to be selected automatically based on the destination IP address.
lport
- Our port, zero for the next one available in the range 1025-65536.
remip
- IP address to connect to.
port
- Port to connect to.
datahandler
- Function to call when data is received,
NULLfor placing data in the socket's receive buffer. Prior to Dynamic C 7.30, some details for implementation of this service had not been finalized. Insert a value ofNULLif you are using a version of Dynamic C prior to 7.30.
buffer
- Address of user-supplied socket buffer in xmem. This is the return value of
xalloc(). Ifbufferis 0, the socket buffer for this socket is pulled from the buffer pool defined by the macroMAX_TCP_SOCKET_BUFFERS.
buflen
- Length of user-supplied socket buffer.
Return value
0:Error, unable to resolve the remote computer's hardware address.!0: Success.Library
TCP.LIB
See also
| TCP/IP Manual Vol 1 |
<<Previous | Index | Next>> | rabbit.com |