dns resolve

mrdebug
Posts: 43
Joined: Sat Jul 27, 2019 8:26 am

dns resolve

Postby mrdebug » Wed Dec 02, 2020 2:43 pm

Hi, in order to resolve an address I using the function
dns_gethostbyname().
Sometimes the customer uses a standard ip address like 192.168.1.123.
Is there a way to determine if dns_gethostbyname() is necessary or not?

ESP_Sprite
Posts: 9746
Joined: Thu Nov 26, 2015 4:08 am

Re: dns resolve

Postby ESP_Sprite » Thu Dec 03, 2020 1:33 am

I think we support the inet_pton call; you could see if that succeeds before calling dns_gethostbyname.

Who is online

Users browsing this forum: No registered users and 83 guests