<< Previous | Index | Next >>

sock_xfastwrite


int sock_xfastwrite( tcp_Socket *s, long dp, long len );

Description

Writes up to len bytes from dp to socket s. This function writes as many bytes possible to the socket and returns that number of bytes. This function is only valid for TCP sockets. For UDP sockets, use udp_send() or udp_sendto().

This function is identical to sock_fastwrite(), except that an extended memory data source is used.

Parameters

s

Pointer to socket.

dp

Buffer containing data to be written, as an xmem address obtained from, for example, xalloc().

len

Maximum number of bytes to write to the socket.

Return Value

Number of bytes written or -1 if there was an error.

Library

TCP.LIB

See Also

sock_write, sock_fastread, sock_read, sockerr, sock_flush, sock_flushnext, udp_send, udp_sendto, sock_fastwrite


TCP/IP Manual
Vol 1
<<Previous | Index | Next>> rabbit.com