Commit a11e34ae authored by Rob Riepel's avatar Rob Riepel
Browse files

Replace split() with regex capture group

parent c7a56900
......@@ -107,9 +107,9 @@ while (<>) {
}
# dynamic queries
elsif ($qname =~ /.+\.$my_domain$/) {
elsif ($qname =~ /(?<residual>.+)\.$my_domain$/) {
write_log("sending dynamic response for $qname/$qtype");
print handle_lb_request(split(/\./,$qname,2),$qtype,$qclass);
print handle_lb_request($+{residual},$my_domain,$qtype,$qclass);
}
print "END\n";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment