Accept – Comtrol eCos User Manual
Page 554

Chapter 38. TCP/IP Library Reference
The dn_comp() function compresses the domain name exp_dn and stores it in
comp_dn.
The size of the compressed name is returned or -1 if there were
errors.
The size of the array pointed to by comp_dn is given by length.
The compression uses an array of pointers dnptrs to previously compressed
names in the current message.
The first pointer points to the beginning
of the message and the list ends with NULL.
The limit to the array is
specified by lastdnptr.
A side effect of dn_comp() is to update the list
of pointers for labels inserted into the message as the name is com-
pressed.
If dnptr is NULL, names are not compressed.
If lastdnptr is
NULL, the list of labels is not updated.
The dn_expand() entry expands the compressed domain name comp_dn to a
full domain name The compressed name is contained in a query or reply
message; msg is a pointer to the beginning of the message.
The uncom-
pressed name is placed in the buffer indicated by exp_dn which is of size
length.
The size of compressed name is returned or -1 if there was an
error.
FILES
/etc/resolv.conf configuration file see resolv.conf(5).
SEE ALSO
gethostbyname(3), resolv.conf(5), hostname(7), named(8)
RFC1032, RFC1033, RFC1034, RFC1035, RFC1535, RFC974
Name Server Operations Guide for BIND.
HISTORY
The res_query function appeared in 4.3BSD.
BSD
June 4, 1993
BSD
accept
ACCEPT(2)
System Calls Manual
ACCEPT(2)
NAME
accept - accept a connection on a socket
SYNOPSIS
#include
<
sys/types.h>
#include
<
sys/socket.h>
int
accept(int s, struct sockaddr *addr, socklen_t *addrlen);
DESCRIPTION
The argument s is a socket that has been created with socket(2), bound to
an address with bind(2), and is listening for connections after a
listen(2).
The accept() argument extracts the first connection request
on the queue of pending connections, creates a new socket with the same
450