| line |
true |
false |
branch |
|
114
|
6 |
1 |
unless $warned{join $", @note}++ |
|
141
|
4 |
88 |
if (my $file = $args{'config_file'}) { } |
|
|
80 |
8 |
elsif ($init) { } |
|
145
|
1 |
1 |
unless $init |
|
156
|
2 |
74 |
unless $public_attr{$attr} |
|
158
|
4 |
70 |
if $ref and $ref ne "ARRAY" |
|
160
|
24 |
46 |
$ref ? : |
|
181
|
3 |
4 |
unless scalar @value |
|
189
|
1 |
7 |
if defined $ENV{'LOCALDOMAIN'} |
|
191
|
1 |
7 |
if defined $ENV{'RES_NAMESERVERS'} |
|
193
|
1 |
7 |
if defined $ENV{'RES_SEARCHLIST'} |
|
205
|
2 |
17 |
unless my $filehandle = "IO::File"->new($file, "<") |
|
214
|
18 |
72 |
if (/^nameserver/) |
|
220
|
2 |
70 |
if (/^domain/) |
|
226
|
10 |
60 |
if (/^search/) |
|
232
|
2 |
58 |
if (/^option/) |
|
242
|
10 |
7 |
if @nameserver |
|
243
|
10 |
7 |
if @searchlist |
|
250
|
1 |
1 |
unless ref $self |
|
278
|
55 |
44 |
unless ref $self |
|
281
|
26 |
73 |
if scalar @domain |
|
292
|
2 |
230 |
unless ref $self |
|
296
|
289 |
7 |
if (_ipv4($ns) or _ipv6($ns)) { } |
|
315
|
1 |
6 |
unless scalar @address |
|
321
|
96 |
136 |
if (scalar @ns or not defined wantarray) |
|
332
|
124 |
108 |
@IPv6 ? : |
|
333
|
5 |
227 |
if $self->{'prefer_v6'} |
|
334
|
1 |
231 |
if $self->{'prefer_v4'} |
|
335
|
3 |
229 |
if $self->{'force_v6'} |
|
336
|
4 |
228 |
if $self->{'force_v4'} |
|
338
|
10 |
222 |
unless @IPlist |
|
375
|
154 |
264 |
if $text |
|
384
|
2 |
11 |
$self->{'defnames'} && !($name =~ /[.:]/) ? : |
|
389
|
7 |
3 |
$packet->header->ancount ? : |
|
396
|
1 |
6 |
unless $self->{'dnsrch'} |
|
401
|
1 |
5 |
$dots < $self->{'ndots'} ? : |
|
402
|
1 |
1 |
$dots ? : |
|
|
4 |
2 |
$name =~ /:|\.\d*$/ ? : |
|
405
|
2 |
5 |
$suffix ? : |
|
408
|
1 |
1 |
if $packet->header->ancount |
|
423
|
7 |
82 |
if $self->{'usevc'} or length $packet_data > $self->_packetsz |
|
427
|
4 |
61 |
if $self->{'igntc'} |
|
428
|
60 |
1 |
unless $reply->header->tc |
|
454
|
0 |
10 |
unless @ready |
|
463
|
2 |
8 |
unless $self->_accept_reply($reply, $query) |
|
466
|
2 |
6 |
if ($self->{'tsig_rr'} and not $reply->verify($query)) |
|
472
|
3 |
3 |
if $rcode eq "NOERROR" |
|
473
|
1 |
2 |
if $rcode eq "NXDOMAIN" |
|
477
|
1 |
4 |
if $fallback |
|
478
|
2 |
3 |
unless $self->errorstring |
|
491
|
82 |
1 |
$servers ? : |
|
503
|
131 |
51 |
unless (ref $ns) |
|
510
|
51 |
92 |
if $failed |
|
528
|
2 |
68 |
unless $self->_accept_reply($packet, $query) |
|
535
|
24 |
68 |
unless $reply |
|
537
|
2 |
66 |
if ($self->{'tsig_rr'} and not $reply->verify($query)) |
|
543
|
61 |
5 |
if $rcode eq "NOERROR" |
|
544
|
3 |
2 |
if $rcode eq "NXDOMAIN" |
|
553
|
1 |
18 |
if $fallback |
|
554
|
14 |
5 |
unless $self->errorstring |
|
567
|
7 |
9 |
if $self->{'usevc'} or length $packet_data > $self->_packetsz |
|
583
|
2 |
9 |
unless $socket |
|
624
|
2 |
10811 |
unless $handle |
|
628
|
1 |
10810 |
if ref $read |
|
630
|
10796 |
14 |
unless "IO::Select"->new($handle)->can_read("0.02") |
|
632
|
1 |
13 |
unless $query |
|
633
|
7 |
6 |
unless $handle->socktype == 2 |
|
638
|
1 |
5 |
unless $ans |
|
639
|
1 |
4 |
if $self->{'igntc'} |
|
640
|
2 |
2 |
unless $ans->header->tc |
|
662
|
1 |
17 |
unless $handle |
|
666
|
5 |
12 |
if ref $read |
|
668
|
1 |
11 |
unless "IO::Select"->new($handle)->can_read("0.2") |
|
671
|
6 |
5 |
$dgram ? : |
|
679
|
1 |
10 |
unless $self->_accept_reply($reply, $query) |
|
682
|
9 |
1 |
unless $self->{'tsig_rr'} and not $reply->verify($query) |
|
691
|
1 |
95 |
unless $reply |
|
694
|
1 |
94 |
unless $header->qr |
|
696
|
6 |
88 |
if $query and $header->id != $query->header->id |
|
704
|
7 |
2 |
scalar @argument ? : |
|
716
|
6 |
2682 |
if (ref $rr eq "Net::DNS::RR::SOA") |
|
717
|
3 |
3 |
if ($soa) |
|
719
|
2 |
1 |
if $rr->canonical eq $soa->canonical |
|
725
|
28 |
2657 |
unless (scalar @rr) |
|
728
|
27 |
1 |
if $reply |
|
734
|
1 |
2 |
unless wantarray |
|
780
|
3 |
6 |
if ($rcode = $reply->header->rcode) eq "NOERROR" |
|
783
|
2 |
6 |
unless $reply |
|
787
|
3 |
3 |
$request->sigrr ? : |
|
788
|
3 |
3 |
unless ($verify) |
|
789
|
1 |
2 |
unless $rcode eq "NOERROR" |
|
794
|
1 |
2 |
unless $verifyok |
|
795
|
1 |
1 |
if $rcode ne "NOERROR" |
|
806
|
1 |
38 |
unless $socket |
|
810
|
1 |
37 |
if $@ |
|
812
|
27 |
10 |
unless $verify |
|
815
|
1 |
9 |
unless $verifyok |
|
826
|
189 |
106 |
if $size |
|
836
|
0 |
53 |
if length $header < 2 |
|
859
|
2 |
28 |
if ($socket = $self->{'persistent'}{$sock_key}) |
|
861
|
1 |
1 |
if $socket->connected |
|
876
|
1 |
28 |
$ip6_addr ? : |
|
893
|
2 |
27 |
if $self->{'persistent_tcp'} |
|
903
|
1 |
102 |
if $socket = $self->{'persistent'}{$sock_key} |
|
909
|
23 |
79 |
$ip6_addr ? : |
|
926
|
1 |
101 |
if $self->{'persistent_udp'} |
|
947
|
35 |
107 |
_ipv6($ip) ? : |
|
963
|
241 |
356 |
if /[^.0-9]/ |
|
971
|
403 |
294 |
unless /:.*:/ |
|
972
|
290 |
4 |
unless /[^:0-9A-Fa-f]/ |
|
973
|
2 |
2 |
if /^[:.0-9A-Fa-f]+\%.+$/ |
|
984
|
86 |
47 |
unless (ref $packet) |
|
995
|
12 |
120 |
if ($self->{'tsig_rr'}) |
|
996
|
11 |
1 |
unless $packet->sigrr |
|
1015
|
3 |
1 |
if $self->{'force_v6'} = $_ |
|
1016
|
4 |
3 |
$self->{'force_v6'} ? : |
|
1021
|
4 |
1 |
if $self->{'force_v4'} = $_ |
|
1022
|
5 |
3 |
$self->{'force_v4'} ? : |
|
1027
|
4 |
1 |
if $self->{'prefer_v6'} = $_ |
|
1028
|
5 |
3 |
$self->{'prefer_v6'} ? : |
|
1033
|
2 |
1 |
if $self->{'prefer_v4'} = $_ |
|
1034
|
3 |
3 |
$self->{'prefer_v4'} ? : |
|
1040
|
1 |
1 |
_ipv6($_) ? : |
|
1049
|
1 |
8 |
unless $arg |
|
1050
|
1 |
7 |
if ref $arg eq "Net::DNS::RR::TSIG" |
|
1056
|
1 |
6 |
if $@ |
|
1066
|
55 |
47 |
$udpsize > 512 ? : |
|
1086
|
487 |
1 |
unless +(shift())->{'debug'} |
|
1111
|
4 |
2 |
unless scalar @ip |
|
1127
|
1 |
43 |
unless $public_attr{$name} |
|
1131
|
2 |
98 |
unless ref $self |
|
1132
|
76 |
24 |
if scalar @_ |