Die/recv.pm

filter: Statementstmt 100% 10 / 10 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod n/a totaltotal 100% 14 / 14 CC 2 SCAR 5.1
CC
2
Cov
100%
recv
2.0
BEGIN
1.0
CRAP 1.7
« Die/listen.pm ↑ Summary Die/rename.pm »
1 package IO::Die;
2  
3 3 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 6 ▶sub recv {
Subroutine recv: called CC=2 SCAR=6.9
6 6 my ( $NS, $socket, $length, $flags ) = ( shift, shift, @_[ 1 .. $#_ ] );
7  
8 #https://github.com/pjcj/Devel--Cover/issues/125
9 #my ( $NS, $socket, $scalar_r, $length, $flags ) = ( shift, shift, \shift, @_ );
10  
11 6 local ( $!, $^E );
12 6 my $res = CORE::recv( $socket, $_[0], $length, $flags );
13 6 ▶ if ( !defined $res ) {
Branch: 1 branch
BranchTrueFalseTotal
unless (defined $res) 3 3 6
14 3 $NS->__THROW( 'SocketReceive', length => $length, flags => $flags );
15 }
16  
17 3 return $res;
18 }
19  
20 3 1;
« Die/listen.pm ↑ Summary Die/rename.pm »