Changed format of DNS-listen options. Added DNS-thread count options to config.
This commit is contained in:
+2
-2
@@ -176,7 +176,7 @@ impl DnsServer for DnsUdpServer {
|
||||
/// This method takes ownership of the server, preventing the method from being called multiple times.
|
||||
fn run_server(self) -> Result<()> {
|
||||
// Bind the socket
|
||||
let socket = UdpSocket::bind((self.context.dns_host.as_str(), self.context.dns_port))?;
|
||||
let socket = UdpSocket::bind(self.context.dns_listen.as_str())?;
|
||||
|
||||
// Spawn threads for handling requests
|
||||
for thread_id in 0..self.thread_count {
|
||||
@@ -291,7 +291,7 @@ impl DnsTcpServer {
|
||||
|
||||
impl DnsServer for DnsTcpServer {
|
||||
fn run_server(mut self) -> Result<()> {
|
||||
let socket = TcpListener::bind((self.context.dns_host.as_str(), self.context.dns_port))?;
|
||||
let socket = TcpListener::bind(self.context.dns_listen.as_str())?;
|
||||
|
||||
// Spawn threads for handling requests, and create the channels
|
||||
for thread_id in 0..self.thread_count {
|
||||
|
||||
Reference in New Issue
Block a user