line |
true |
false |
branch |
26
|
1 |
10 |
unless @_ |
44
|
1 |
1 |
if ($sock->sockdomain == 2) { } |
|
1 |
0 |
elsif ($sock->sockdomain == 10) { } |
49
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IP(), IP_ADD_MEMBERSHIP(), $ip_mreq |
56
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IPV6(), IPV6_JOIN_GROUP(), $ipv6_mreq |
72
|
0 |
0 |
if ($sock->sockdomain == 2) { } |
|
0 |
0 |
elsif ($sock->sockdomain == 10) { } |
79
|
0 |
0 |
unless setsockopt $sock, IPPROTO_IP(), IP_ADD_SOURCE_MEMBERSHIP(), $ip_mreq |
97
|
1 |
1 |
if ($sock->sockdomain == 2) { } |
|
1 |
0 |
elsif ($sock->sockdomain == 10) { } |
102
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IP(), IP_DROP_MEMBERSHIP(), $ip_mreq |
109
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IPV6(), IPV6_LEAVE_GROUP(), $ipv6_mreq |
124
|
3 |
3 |
if ($sock->sockdomain == 2) { } |
|
3 |
0 |
elsif ($sock->sockdomain == 10) { } |
125
|
0 |
3 |
unless my $packed = getsockopt($sock, IPPROTO_IP(), IP_MULTICAST_TTL()) |
128
|
1 |
2 |
if (my $ttl = shift()) |
129
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IP(), IP_MULTICAST_TTL(), pack('I', $ttl) |
133
|
0 |
3 |
unless my $packed = getsockopt($sock, IPPROTO_IPV6(), IPV6_MULTICAST_HOPS()) |
136
|
1 |
2 |
if (my $ttl = shift()) |
137
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IPV6(), IPV6_MULTICAST_HOPS(), pack('I', $ttl) |
152
|
3 |
3 |
if ($sock->sockdomain == 2) { } |
|
3 |
0 |
elsif ($sock->sockdomain == 10) { } |
153
|
0 |
3 |
unless my $packed = getsockopt($sock, IPPROTO_IP(), IP_MULTICAST_LOOP()) |
156
|
1 |
2 |
if (my $loopback = shift()) |
157
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IP(), IP_MULTICAST_LOOP(), pack('I', $loopback) |
161
|
0 |
3 |
unless my $packed = getsockopt($sock, IPPROTO_IPV6(), IPV6_MULTICAST_LOOP()) |
165
|
1 |
2 |
if (my $loopback = shift()) |
166
|
0 |
1 |
unless setsockopt $sock, IPPROTO_IPV6(), IPV6_MULTICAST_LOOP(), pack('I', $loopback) |
181
|
0 |
0 |
if ($sock->sockdomain == 2) { } |
|
0 |
0 |
elsif ($sock->sockdomain == 10) { } |
182
|
0 |
0 |
unless my $packed = getsockopt($sock, IPPROTO_IP(), IP_MULTICAST_IF()) |
186
|
0 |
0 |
if (my $interface = shift()) |
188
|
0 |
0 |
unless setsockopt $sock, IPPROTO_IP(), IP_MULTICAST_IF(), inet_pton(2, $if_addr) |
192
|
0 |
0 |
unless my $packed = getsockopt($sock, IPPROTO_IPV6(), IPV6_MULTICAST_IF()) |
195
|
0 |
0 |
if ($prev == 0) { } |
198
|
0 |
0 |
if (my $interface = shift()) |
200
|
0 |
0 |
unless setsockopt $sock, IPPROTO_IPV6(), IPV6_MULTICAST_IF(), pack('I', $if_index) |
216
|
6 |
8 |
if (defined $addr) |
217
|
3 |
3 |
if ($sock->sockdomain == 2) { } |
|
3 |
0 |
elsif ($sock->sockdomain == 10) { } |
218
|
1 |
2 |
if (not defined $port and $addr =~ /^($IPv4):(\d+)$/) |
222
|
2 |
1 |
if defined $port |
223
|
0 |
3 |
if not defined $addr or length $addr == 0 |
224
|
0 |
3 |
unless sockaddr_family($addr) == 2 |
227
|
1 |
2 |
if (not defined $port and $addr =~ /^\[($IPv6)\]:(\d+)$/) |
231
|
2 |
1 |
if defined $port |
232
|
0 |
3 |
if not defined $addr or length $addr == 0 |
233
|
0 |
3 |
unless sockaddr_family($addr) == 10 |
250
|
0 |
2 |
if @_ |
262
|
2 |
0 |
unless defined $interface |
263
|
0 |
0 |
if $interface eq 'any' |
264
|
0 |
0 |
if $interface =~ /^$IPv4$/ |
267
|
0 |
0 |
unless defined $if |
268
|
0 |
0 |
unless $if->is_multicast |
270
|
0 |
0 |
unless defined $address |
280
|
2 |
0 |
unless defined $interface |
281
|
0 |
0 |
if $interface =~ /^\d+$/ |
282
|
0 |
0 |
if $interface =~ /^any$/i |
285
|
0 |
0 |
unless defined $if |
286
|
0 |
0 |
unless $if->is_multicast |
288
|
0 |
0 |
unless defined $index |