Alien-cares

 view release on metacpan or  search on metacpan

libcares/ares_platform.c  view on Meta::CPAN

{"ezproxy-2",          {NULL}, 10102, "tcp"},
{"ezproxy-2",          {NULL}, 10102, "udp"},
{"ezrelay",            {NULL}, 10103, "tcp"},
{"ezrelay",            {NULL}, 10103, "udp"},
{"swdtp",              {NULL}, 10104, "tcp"},
{"swdtp",              {NULL}, 10104, "udp"},
{"bctp-server",        {NULL}, 10107, "tcp"},
{"bctp-server",        {NULL}, 10107, "udp"},
{"nmea-0183",          {NULL}, 10110, "tcp"},
{"nmea-0183",          {NULL}, 10110, "udp"},
{"netiq-endpoint",     {NULL}, 10113, "tcp"},
{"netiq-endpoint",     {NULL}, 10113, "udp"},
{"netiq-qcheck",       {NULL}, 10114, "tcp"},
{"netiq-qcheck",       {NULL}, 10114, "udp"},
{"netiq-endpt",        {NULL}, 10115, "tcp"},
{"netiq-endpt",        {NULL}, 10115, "udp"},
{"netiq-voipa",        {NULL}, 10116, "tcp"},
{"netiq-voipa",        {NULL}, 10116, "udp"},
{"iqrm",               {NULL}, 10117, "tcp"},
{"iqrm",               {NULL}, 10117, "udp"},
{"bmc-perf-sd",        {NULL}, 10128, "tcp"},
{"bmc-perf-sd",        {NULL}, 10128, "udp"},

libcares/ares_set_socket_functions.3  view on Meta::CPAN

The \fIuser_data\fP value is provided to each callback function invocation to serve as
context.
.PP
The
.B ares_socket_functions
must provide the following callbacks:
.TP 18
.B \fIasocket\fP
.B ares_socket_t(*)(int \fIdomain\fP, int \fItype\fP, int \fIprotocol\fP, void * \fIuser_data\fP)
.br
Creates an endpoint for communication and returns a descriptor. \fIdomain\fP, \fItype\fP, and \fIprotocol\fP
each correspond to the parameters of
.BR socket(2).
Returns ahandle to the newly created socket, or -1 on error.
.TP 18
.B \fIaclose\fP
.B int(*)(ares_socket_t \fIfd\fP, void * \fIuser_data\fP)
.br
Closes the socket endpoint indicated by \fIfd\fP. See
.BR close(2)
.TP 18
.B \fIaconnect\fP
.B int(*)(ares_socket_t \fIfd\fP, const struct sockaddr * \fIaddr\fP, ares_socklen_t \fIaddr_len\fP, void * \fIuser_data\fP)
.br
Initiate a connection to the address indicated by \fIaddr\fP on a socket. See
.BR connect(2)

.TP 18
.B \fIarecvfrom\fP
.B ares_ssize_t(*)(ares_socket_t \fIfd\fP, void * \fIbuffer\fP, size_t \fIbuf_size\fP, int \fIflags\fP, struct sockaddr * \fIaddr\fP, ares_socklen_t * \fIaddr_len\fP, void * \fIuser_data\fP)
.br
Receives data from remote socket endpoint, if available. If the \fIaddr\fP parameter is not NULL and the connection protocol provides the source address, the callback should fill this in. See
.BR recvfrom(2)

.TP 18
.B \fIasendv\fP
.B ares_ssize_t(*)(ares_socket_t \fIfd\fP, const struct iovec * \fIdata\fP, int \fIlen\fP, void * \fIuser_data\fP)
.br
Send data, as provided by the iovec array \fIdata\fP, to the socket endpoint. See
.BR writev(2),

.PP
The
.B ares_socket_functions
struct provided is not copied but directly referenced,
and must thus remain valid through out the channels and any created socket's lifetime.
.SH AVAILABILITY
Added in c-ares 1.13.0
.SH SEE ALSO

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 1.042 second using v1.00-cache-2.02-grep-82fe00e-cpan-4673cadbf75 )