FARGOS/VISTA Object Management Environment Core
..
|
#include <stdio.h>
#include <OMEdebugInfo.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/ioctl.h>
#include <fcntl.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <sys/un.h>
#include <unistd.h>
#include <netdb.h>
#include <errno.h>
#include <sys/uio.h>
Macros | |
#define | OME_SUPPORT_FOR_AF_UNIX /* All Unix platforms support AF_UNIX */ |
#define | OUR_sockaddr_in6 struct sockaddr_in6 |
Functions | |
uint32_t | if_nametoindex (const char *ifname) |
char * | if_indextoname (uint32_t ifindex, char *ifname) |
OMEstring * | OMEdisplayableAddress (const struct sockaddr *sock, const int len, const uint32_t openMode) |
Convert sockaddr data into a text string. More... | |
int | OMEtransportToSockaddr (sockBigEnough *sock, uint_fast16_t *sockLen, int *sockMode, const char *url, uint_fast16_t urlLen) |
Convert textual transport address into sockaddr structure. More... | |
#define OME_SUPPORT_FOR_AF_UNIX /* All Unix platforms support AF_UNIX */ |
#define OUR_sockaddr_in6 struct sockaddr_in6 |
char* if_indextoname | ( | uint32_t | ifindex, |
char * | ifname | ||
) |
Referenced by OMEdisplayableAddress().
uint32_t if_nametoindex | ( | const char * | ifname | ) |
Referenced by OMEtransportToSockaddr().
int OMEtransportToSockaddr | ( | sockBigEnough * | sock, |
uint_fast16_t * | sockLen, | ||
int * | sockMode, | ||
const char * | url, | ||
uint_fast16_t | urlLen | ||
) |
Convert textual transport address into sockaddr structure.
sock | points at a sockaddr structure that is large enough to hold the transport data. |
sockLen | points to an integer indicating the size of the sock structure. Upon entry it should indicate the total amount of space available; upon exit it is adjusted to indicate the actual size used. |
sockMode | is a pointer to an integer that will be filled in with additional data describing the type of the connection. A null pointer may be specified if this information is not desired. |
url | points to the text string describing the transport address. |
urlLen | indicates the length of the text. |
0 | indicates an unsupported type. |
1 | indicates a successful conversion was performed. |
References AND_OUTPUT_NLM, DEFINE_NLM_MESSAGE, htons, if_nametoindex(), NEXT_NLM_PARAM, NOTE_DEFAULT_NLM, OME_IO_CONNECT, OME_IO_DATAGRAM, OME_IO_LISTEN, OME_IO_NONBLOCKING, OME_IO_RAW, OMEdebugBadParameter, OUR_sockaddr_in6, and sock.
Referenced by lookupAddress(), and OMEsocketDescriptor::openSocketScheme().
![]() | Generated: Fri Jul 31 2020 18:19:15
Support Information |