influxdb-cpp
influxdb-cpp copied to clipboard
Added conversion of hostname to IP
Dear Orca,
thank you very much for this neat piece of code!
I added the support to connect to influxdb using the hostname instead of the IP address.
Cheers, Ben
Please accept this pull request since I had to add it manually once I cloned the repo without knowing that this was already solved but not added.
Dear Ben,
Thanks to your contribution.
The feature helps when put in a hostname instead of IP address.
But inet_ntoa is not thread-safe, inet_ntop maybe better.
And I think new solution should be found to instead std::exit when failed to translate hostname to IP address.
Best Regards, Orca