tfDnsSetServer

Jump to: navigation, search

Table of Contents >> Application Reference >> DNS Resolver

Note Note: The content on this page has been deprecated.
For the new content, please see tfNgDnsSetServer().


#include <trsocket.h>


int tfDnsSetServer (
ttUserIpAddress serverIpAddr,
int serverNumber
);


Function Description

This function sets the IPv4 address of the primary and secondary DNS server. To set the primary DNS server serverNumber should be set to TM_DNS_PRI_SERVER; for the secondary server it should be set to TM_DNS_SEC_SERVER. To remove a previously set entry, set serverIpAddr to zero.


Parameters

  • serverIpAddr
    The IP address of the DNS server.
  • serverNumber
    The number of the server.


Returns

  • TM_EINVAL
    The serverNumber was invalid.
  • TM_ENOERROR
    Success.


Table of Contents >> Application Reference >> DNS Resolver