From f35e3e3efe4c724f19594e2a41772b329d890cb8 Mon Sep 17 00:00:00 2001 From: Guillaume Mazoyer Date: Mon, 13 Jun 2016 11:41:49 +0200 Subject: Fix hostname_to_ip_address. Get only AAAA or A record based on the router config if provided. --- routers/bird.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'routers/bird.php') diff --git a/routers/bird.php b/routers/bird.php index 9a6c869..fee3736 100644 --- a/routers/bird.php +++ b/routers/bird.php @@ -28,7 +28,7 @@ final class Bird extends Router { if (match_hostname($destination)) { $hostname = $destination; - $destination = hostname_to_ip_address($hostname); + $destination = hostname_to_ip_address($hostname, $this->config); if (!$destination) { throw new Exception('No record found for '.$hostname); @@ -65,7 +65,7 @@ final class Bird extends Router { if (match_hostname($destination)) { $hostname = $destination; - $destination = hostname_to_ip_address($hostname); + $destination = hostname_to_ip_address($hostname, $this->config); if (!$destination) { throw new Exception('No record found for '.$hostname); -- cgit v1.2.3