DnsQuery for NetworkSocketAPI
Fork of DnsQuery by
Diff: DnsQuery.cpp
- Branch:
- api-changes
- Revision:
- 5:d85c1a7e0e9f
- Parent:
- 4:3749346dcd59
- Child:
- 6:5b28cbc8169c
--- a/DnsQuery.cpp Mon Feb 22 19:31:19 2016 -0600 +++ b/DnsQuery.cpp Mon Feb 22 19:38:10 2016 -0600 @@ -38,7 +38,7 @@ -DnsQuery::DnsQuery(SocketInterface *sock,const char* hostname, char* ipaddress) +DnsQuery::DnsQuery(UDPSocket *sock,const char* hostname, char* ipaddress) { socket = sock; this->getHostByName(hostname, ipaddress); @@ -112,7 +112,8 @@ // Ready to send to DNS - socket->setAddressPort(_dnsip, 53); + socket->setIPAddress(_dnsip); + socket->setPort(53); socket->open(); INFO("Sending packet of length %d",packetlen);