Skip to content
Snippets Groups Projects
Commit 5f43b6a5 authored by Benoît Canet's avatar Benoît Canet Committed by Avi Kivity
Browse files

dhcp: wire dhcp dns servers with the libc DNS resolver code.


This Close issue #8 ""Make Java InetAddress.getHostName() works".

Signed-off-by: default avatarBenoit Canet <benoit@irqsave.net>
Signed-off-by: default avatarAvi Kivity <avi@cloudius-systems.com>
parent bab9b9e1
No related branches found
No related tags found
No related merge requests found
......@@ -29,6 +29,11 @@
#include <dhcp.hh>
#include <drivers/clock.hh>
namespace osv {
void set_dns_config(std::vector<boost::asio::ip::address> nameservers,
std::vector<std::string> search_domains);
}
using namespace boost::asio;
dhcp::dhcp_worker net_dhcp_worker;
......@@ -496,6 +501,7 @@ namespace dhcp {
osv_route_add_network("0.0.0.0",
"0.0.0.0",
dm.get_router_ip().to_string().c_str());
osv::set_dns_config(dm.get_dns_ips(), std::vector<std::string>());
// Send a DHCP Request
_state = DHCP_REQUEST;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment