Subject: | net::dns::resolver no longer sets errorstring |
Hello,
I check $res->errorstring after a resolver object, but that appears to no longer exist:
$ ./dyndns-update.pl
none.asdsdg.com
Net::DNS::Resolver {
Parents Net::DNS::Resolver::UNIX
public methods (2) : CONFIG, OS_CONF
private methods (0)
internals: {
adflag 0,
cdflag 0,
debug 0,
defnames 1,
dnsrch 1,
dnssec 0,
force_v4 0,
force_v6 0,
igntc 0,
nameservers [
[0] "89.15.176.90"
],
nameserver4 [
[0] "89.15.176.90"
],
nameserver6 [],
ndots 1,
persistent_tcp 0,
persistent_udp 0,
port 53,
prefer_v4 0,
prefer_v6 0,
recurse 1,
retrans 5,
retry 4,
searchlist [
[0] "something.de"
],
srcaddr4 "0.0.0.0",
srcaddr6 "::",
srcport 0,
tcp_timeout 120,
udp_timeout 30,
udppacketsize 0,
usevc 0
}
}
This breaks my script, and there seems to be no other way to see if the resolver was created OK. I would expect errorstrint to be NOERROR (as in teh past) or something else helpful, as I check:
# check $res object... if no network, there will be an error
if ($res->errorstring ne "NOERROR") {
print "Resolver $server failed: ", $res->errorstring, "\n";
p $res;
$ip = "0.0.0.0";
return $ip;
}