OpenDOF Project
DOFAddress InetTransport_CreateAddress_Interface ( const char *  hostname,
uint16  port,
const char *  iface 
)

Create a new address from hostname, port and an interface name e.g.

eth0, wlan0.

Note
Hostname will be resolved and reresolved when needed.
The interface index will only be used to force a multicast server to listen on a specific interface; it is ignored for all other address types and uses.
Parameters
hostnameThe hostname this should not be NULL.
portThe port number.
ifaceThe interface name over which a multicast address is valid. 0 (the default) means the platform will choose the most appropriate interface.
Returns
The new address, or NULL if one could not be created. If the SO_BINDTODEVICE socket option is not supported and the interface is greater than 0, this function will return NULL.
Resource Management:
This function allocates resources that must later be freed by calling DOFAddress_Destroy.
core-c-dof-inet-posix Version 2.0.2 Build 0
2017-04-26