Home |
Function xn_add_host_table_entry Function xn_delete_host_table_entry Function xn_interface_open_config Function xn_interface_ethernet_statistics Function xn_interface_statistics Function xn_send_ethernet_frame Function cb_wr_screen_string_fnc Function cb_rs232_connection_lost_fnc |
Function xn_add_host_table_entryThis function adds an entry to the list of DNS resolved IP/host name pairs. It is equivalent to adding an entry to the hosts file under Unix or Windows. int xn_add_host_table_entry(const char * name, DWORD ipaddr); ParametersnamePointer to host name to add. ipaddrCorresponding IP address in network byte order. return valueReturns 0 if successful, otherwise SOCKET_ERROR. If an error occurred, call xn_getlasterror and xn_geterror_string to return the error value. Section Error Codes further describes each error. This function adds an entry to the global host table which is the first place gethostbyname searches when resolving a domain name, and gethostbyaddr searches when resolving an IP address. You must call xn_set_server_list before this function can be used.
|