| 1 | =pod | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 3 | =head1 NAME | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 4 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 5 | Net::OSCAR::Utility -- internal utility functions for Net::OSCAR | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 6 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 7 | =head1 VERSION | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 8 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 9 | version 1.928 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 10 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 11 | =cut | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 12 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 13 | package Net::OSCAR::Utility; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 14 | 5 | ▶ | BEGIN { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 15 | 5 | $Net::OSCAR::Utility::VERSION = '1.928'; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 16 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 17 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 18 | 5 | $REVISION = '$Revision$'; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 19 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 20 | 5 | ▶ | use strict; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 21 | 5 | ▶ | use vars qw(@ISA @EXPORT); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 22 | 5 | ▶ | use Digest::MD5 qw(md5); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 23 | 5 | ▶ | use Carp; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 24 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 25 | 5 | ▶ | use Net::OSCAR::TLV; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 26 | 5 | ▶ | use Net::OSCAR::Common qw(:loglevels); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 27 | 5 | ▶ | use Net::OSCAR::Constants; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 28 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 29 | 5 | require Exporter; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 30 | 5 | @ISA = qw(Exporter); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 31 | 5 | @EXPORT = qw( | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 32 | randchars log_print log_printf log_print_cond log_printf_cond hexdump normalize tlv_decode tlv_encode send_error bltie | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 33 | signon_tlv encode_password send_versions hash_iter_reset millitime | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 34 | ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 35 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 36 | 5 | eval { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 37 | 5 | require Time::HiRes; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 38 | }; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 39 | 5 | ▶ | our $finetime = $@ ? 0 : 1; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 40 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 41 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 42 | 0 | ▶ | sub millitime() { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
millitime: not called CC=2 SCAR=17.9
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 43 | 0 | ▶ | my $time = $finetime ? Time::HiRes::time() : time(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 44 | 0 | return int($time * 1000); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 45 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 46 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 47 | 0 | ▶ | sub randchars($) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
randchars: not called CC=2 SCAR=17.9
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 48 | 0 | my $count = shift; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 49 | 0 | my $retval = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 50 | 0 | ▶ | for(my $i = 0; $i < $count; $i++) { $retval .= chr(int(rand(256))); } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 51 | 0 | return $retval; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 52 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 53 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 54 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 55 | 0 | ▶ | sub log_print($$@) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
log_print: not called CC=7 SCAR=40.3
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 56 | 0 | my($obj, $level) = (shift, shift); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 57 | 0 | ▶ | my $session = exists($obj->{session}) ? $obj->{session} : $obj; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 58 | 0 | ▶ | return unless defined($session->{LOGLEVEL}) and $session->{LOGLEVEL} >= $level; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
MC/DC0%0/2
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
defined $session->{"LOGLEVEL"}
$session->{"LOGLEVEL"} >= $level
Truth table0%0/3
A and B
A= defined $session->{"LOGLEVEL"}B= $session->{"LOGLEVEL"} >= $level
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 59 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 60 | 0 | my $message = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 61 | 0 | ▶ | $message .= $obj->{description}. ": " if $obj->{description}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 62 | 0 | $message .= join("", @_). "\n"; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 63 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 64 | 0 | ▶ | if($session->{callbacks}->{log}) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 65 | 0 | $session->callback_log($level, $message); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 66 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 67 | 0 | ▶ | $message = "(".$session->{screenname}.") $message" if $session->{SNDEBUG}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 68 | 0 | print STDERR $message; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 69 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 70 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 71 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 72 | 0 | ▶ | sub log_printf($$@) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
log_printf: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 73 | 0 | my($obj, $level, $fmtstr) = (shift, shift, shift); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 74 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 75 | 0 | $obj->log_print($level, sprintf($fmtstr, @_)); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 76 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 77 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 78 | 0 | ▶ | sub log_printf_cond($$&) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
log_printf_cond: not called CC=4 SCAR=30.0
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 79 | 0 | my($obj, $level, $sub) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 80 | 0 | ▶ | my $session = exists($obj->{session}) ? $obj->{session} : $obj; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 81 | 0 | ▶ | return unless defined($session->{LOGLEVEL}) and $session->{LOGLEVEL} >= $level; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
MC/DC0%0/2
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
defined $session->{"LOGLEVEL"}
$session->{"LOGLEVEL"} >= $level
Truth table0%0/3
A and B
A= defined $session->{"LOGLEVEL"}B= $session->{"LOGLEVEL"} >= $level
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 82 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 83 | 0 | log_printf($obj, $level, &$sub); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 84 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 85 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 86 | 0 | ▶ | sub log_print_cond($$&) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
log_print_cond: not called CC=4 SCAR=30.0
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 87 | 0 | my($obj, $level, $sub) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 88 | 0 | ▶ | my $session = exists($obj->{session}) ? $obj->{session} : $obj; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 89 | 0 | ▶ | return unless defined($session->{LOGLEVEL}) and $session->{LOGLEVEL} >= $level; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
MC/DC0%0/2
defined $session->{"LOGLEVEL"} and $session->{"LOGLEVEL"} >= $level
defined $session->{"LOGLEVEL"}
$session->{"LOGLEVEL"} >= $level
Truth table0%0/3
A and B
A= defined $session->{"LOGLEVEL"}B= $session->{"LOGLEVEL"} >= $level
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 90 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 91 | 0 | log_print($obj, $level, &$sub); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 92 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 93 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 94 | 0 | ▶ | sub hexdump($;$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
hexdump: not called CC=19 SCAR=59.4
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 95 | 0 | my $stuff = shift; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 96 | 0 | ▶ | my $forcehex = shift || 0; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition0%0/2
shift() || 0
MC/DC0%0/1
shift() || 0
shift()
Truth table0%0/2
A
A= shift()
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 97 | 0 | my $retbuff = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 98 | 0 | my @stuff; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 99 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 100 | 0 | ▶ | return "" unless defined($stuff); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 101 | 0 | ▶ | for(my $i = 0; $i < length($stuff); $i++) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 102 | 0 | push @stuff, substr($stuff, $i, 1); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 103 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 104 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 105 | 0 | ▶ | return $stuff unless $forcehex or grep { $_ lt chr(0x20) or $_ gt chr(0x7E) } @stuff; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/6
$forcehex or grep {$_ lt " " or $_ gt "~";} @stuff
$_ lt ' ' || $_ gt '~'
MC/DC0%0/2
$forcehex or grep {$_ lt " " or $_ gt "~";} @stuff
$forcehex
grep {$_ lt " " or $_ gt "~";} @stuff
MC/DC0%0/2
$_ lt ' ' || $_ gt '~'
$_ lt ' '
$_ gt '~'
Truth table0%0/3
A or B
A= $forcehexB= grep {$_ lt " " or $_ gt "~";} @stuff
Truth table0%0/3
A || B
A= $_ lt ' 'B= $_ gt '~'
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 106 | 0 | ▶ | while(@stuff) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 107 | 0 | my $i = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 108 | 0 | $retbuff .= "\n\t"; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 109 | 0 | my @currstuff = splice(@stuff, 0, 16); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 110 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 111 | 0 | foreach my $currstuff(@currstuff) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 112 | 0 | ▶ | $retbuff .= " " unless $i % 4; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 113 | 0 | ▶ | $retbuff .= " " unless $i % 8; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 114 | 0 | $retbuff .= sprintf "%02X ", ord($currstuff); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 115 | 0 | $i++; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 116 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 117 | 0 | ▶ | for(; $i < 16; $i++) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 118 | 0 | ▶ | $retbuff .= " " unless $i % 4; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 119 | 0 | ▶ | $retbuff .= " " unless $i % 8; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 120 | 0 | $retbuff .= " "; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 121 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 122 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 123 | 0 | $retbuff .= " "; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 124 | 0 | $i = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 125 | 0 | foreach my $currstuff(@currstuff) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 126 | 0 | ▶ | $retbuff .= " " unless $i % 4; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 127 | 0 | ▶ | $retbuff .= " " unless $i % 8; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 128 | 0 | ▶ | if($currstuff ge chr(0x20) and $currstuff le chr(0x7E)) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
$currstuff ge " " and $currstuff le "~"
MC/DC0%0/2
$currstuff ge " " and $currstuff le "~"
$currstuff ge " "
$currstuff le "~"
Truth table0%0/3
A and B
A= $currstuff ge " "B= $currstuff le "~"
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 129 | 0 | $retbuff .= $currstuff; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 130 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 131 | 0 | $retbuff .= "."; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 132 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 133 | 0 | $i++; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 134 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 135 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 136 | 0 | return $retbuff; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 137 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 138 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 139 | 4 | ▶ | sub normalize($) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
normalize: called CC=3 SCAR=11.7
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 140 | 4 | my $temp = shift; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 141 | 4 | ▶ | $temp =~ tr/ //d if $temp; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 142 | 4 | ▶ | return $temp ? lc($temp) : ""; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 143 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 144 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 145 | 0 | ▶ | sub tlv_decode($;$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
tlv_decode: not called CC=9 SCAR=45.0
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 146 | 0 | my($tlv, $tlvcnt) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 147 | 0 | my($type, $len, $value, %retval); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 148 | 0 | my $currtlv = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 149 | 0 | my $strpos = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 150 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 151 | 0 | my $retval = tlv; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 152 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 153 | 0 | ▶ | $tlvcnt = 0 unless $tlvcnt; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 154 | 0 | ▶ | while(length($tlv) >= 4 and (!$tlvcnt or $currtlv < $tlvcnt)) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/6
length $tlv >= 4 and !$tlvcnt || $currtlv < $tlvcnt
not $tlvcnt or $currtlv < $tlvcnt
MC/DC0%0/3
length $tlv >= 4 and !$tlvcnt || $currtlv < $tlvcnt
length $tlv >= 4
not $tlvcnt
$currtlv < $tlvcnt
Truth table0%0/4
A and not(B) or C
A= length $tlv >= 4B= not $tlvcntC= $currtlv < $tlvcnt
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 155 | 0 | ($type, $len) = unpack("nn", $tlv); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 156 | 0 | ▶ | $len = 0x2 if $type == 0x13; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 157 | 0 | $strpos += 4; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 158 | 0 | substr($tlv, 0, 4) = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 159 | 0 | ▶ | if($len) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 160 | 0 | ($value) = substr($tlv, 0, $len, ""); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 161 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 162 | 0 | $value = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 163 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 164 | 0 | $strpos += $len; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 165 | 0 | ▶ | $currtlv++ unless $type == 0; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 166 | 0 | $retval->{$type} = $value; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 167 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 168 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 169 | 0 | ▶ | return $tlvcnt ? ($retval, $strpos) : $retval; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 170 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 171 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 172 | 0 | ▶ | sub tlv_encode($) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
tlv_encode: not called CC=7 SCAR=40.3
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 173 | 0 | my $tlv = shift; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 174 | 0 | my($buffer, $type, $value) = ("", 0, ""); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 175 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 176 | 0 | ▶ | confess "You must use a tied Net::OSCAR::TLV hash!" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/9
defined $tlv and ref $tlv eq "HASH" and defined tied %$tlv and tied(%$tlv)->isa("Net::OSCAR::TLV")
defined $tlv and ref $tlv eq "HASH" and defined tied %$tlv
defined $tlv and ref $tlv eq "HASH"
MC/DC0%0/4
defined $tlv and ref $tlv eq "HASH" and defined tied %$tlv and tied(%$tlv)->isa("Net::OSCAR::TLV")
defined $tlv
ref $tlv eq "HASH"
defined tied %$tlv
tied(%$tlv)->isa("Net::OSCAR::TLV")
Truth table0%0/5
A and B and C and D
A= defined $tlvB= ref $tlv eq "HASH"C= defined tied %$tlvD= tied(%$tlv)->isa("Net::OSCAR::TLV")
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 177 | unless defined($tlv) and ref($tlv) eq "HASH" and defined(tied(%$tlv)) and tied(%$tlv)->isa("Net::OSCAR::TLV"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 178 | 0 | ▶ | while (($type, $value) = each %$tlv) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 179 | 0 | ▶ | $value ||= ""; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition0%0/2
$value ||= ""
MC/DC0%0/1
$value ||= ""
$value
Truth table0%0/2
A
A= $value
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 180 | 0 | $buffer .= pack("nna*", $type, length($value), $value); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 181 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 182 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 183 | 0 | return $buffer; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 184 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 185 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 186 | 0 | ▶ | sub send_error($$$$$;@) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
send_error: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 187 | 0 | my($oscar, $connection, $error, $desc, $fatal, @reqdata) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 188 | 0 | $desc = sprintf $desc, @reqdata; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 189 | 0 | $oscar->callback_error($connection, $error, $desc, $fatal); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 190 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 191 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 192 | 2 | ▶ | sub bltie(;$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
bltie: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 193 | 2 | my $retval = {}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 194 | 2 | tie %$retval, "Net::OSCAR::Buddylist", @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 195 | 2 | return $retval; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 196 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 197 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 198 | 0 | ▶ | sub signon_tlv($;$$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
signon_tlv: not called CC=5 SCAR=34.0
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 199 | 0 | my($session, $password, $key) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 200 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 201 | my %protodata = ( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 202 | screenname => $session->{screenname}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 203 | clistr => $session->{svcdata}->{clistr}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 204 | supermajor => $session->{svcdata}->{supermajor}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 205 | major => $session->{svcdata}->{major}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 206 | minor => $session->{svcdata}->{minor}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 207 | subminor => $session->{svcdata}->{subminor}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 208 | build => $session->{svcdata}->{build}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 209 | subbuild => $session->{svcdata}->{subbuild}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 210 | 0 | ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 211 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 212 | 0 | ▶ | if($session->{svcdata}->{hashlogin}) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 213 | 0 | $protodata{password} = encode_password($session, $password); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 214 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 215 | 0 | ▶ | if($session->{auth_response}) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 216 | 0 | $protodata{auth_response} = delete $session->{auth_response}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 217 | 0 | ▶ | $protodata{pass_is_hashed} = "" if delete $session->{pass_is_hashed}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 218 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 219 | # As of AIM 5.5, the password can be MD5'd before | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 220 | # going into the things-to-cat-together-and-MD5. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 221 | # This lets applications that store AIM passwords | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 222 | # store the MD5'd password. We do it by default | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 223 | # because, well, AIM for Windows does. We support | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 224 | # the old way to preserve compatibility with | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 225 | # our auth_challenge/auth_response API. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 226 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 227 | 0 | $protodata{pass_is_hashed} = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 228 | 0 | ▶ | my $hashpass = $session->{pass_is_hashed} ? $password : md5($password); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 229 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 230 | 0 | $protodata{auth_response} = encode_password($session, $hashpass, $key); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 231 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 232 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 233 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 234 | 0 | return %protodata; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 235 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 236 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 237 | 0 | ▶ | sub encode_password($$;$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
encode_password: not called CC=3 SCAR=24.8
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 238 | 0 | my($session, $password, $key) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 239 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 240 | 0 | ▶ | if(!$session->{svcdata}->{hashlogin}) { # Use new SNAC-based method | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 241 | 0 | my $md5 = Digest::MD5->new; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 242 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 243 | 0 | $md5->add($key); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 244 | 0 | $md5->add($password); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 245 | 0 | $md5->add("AOL Instant Messenger (SM)"); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 246 | 0 | return $md5->digest(); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 247 | } else { # Use old roasting method. Courtesy of SDiZ Cheng. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 248 | 0 | my $ret = ""; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 249 | 0 | my @pass = map {ord($_)} split(//, $password); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 250 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 251 | 0 | my @encoding_table = map {hex($_)} qw( | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 252 | F3 26 81 C4 39 86 DB 92 71 A3 B9 E6 53 7A 95 7C | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 253 | ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 254 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 255 | 0 | ▶ | for(my $i = 0; $i < length($password); $i++) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 256 | 0 | $ret .= chr($pass[$i] ^ $encoding_table[$i]); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 257 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 258 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 259 | 0 | return $ret; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 260 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 261 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 262 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 263 | 0 | ▶ | sub send_versions($$;$) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
send_versions: not called CC=7 SCAR=40.3
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 264 | 0 | my($connection, $send_tools, $server) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 265 | 0 | my $conntype = $connection->{conntype}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 266 | 0 | my @services; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 267 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 268 | 0 | ▶ | if($conntype != CONNTYPE_BOS and !$server) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
$conntype != "basic OSCAR services" and not $server
MC/DC0%0/2
$conntype != "basic OSCAR services" and not $server
$conntype != "basic OSCAR services"
not $server
Truth table0%0/3
A and not(B)
A= $conntype != "basic OSCAR services"B= not $server
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 269 | 0 | @services = (1, $conntype); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 270 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 271 | 0 | @services = sort {$b <=> $a} grep {not OSCAR_TOOLDATA()->{$_}->{nobos}} keys %{OSCAR_TOOLDATA()}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 272 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 273 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 274 | 0 | my %protodata = (service => []); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 275 | 0 | foreach my $service (@services) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 276 | my %service = ( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 277 | service_id => $service, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 278 | service_version => OSCAR_TOOLDATA->{$service}->{version} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 279 | 0 | ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 280 | 0 | ▶ | if($send_tools) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 281 | 0 | $service{tool_id} = OSCAR_TOOLDATA->{$service}->{toolid}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 282 | 0 | $service{tool_version} = OSCAR_TOOLDATA->{$service}->{toolversion}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 283 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 284 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 285 | 0 | push @{$protodata{service}}, \%service; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 286 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 287 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 288 | 0 | ▶ | if($send_tools) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 289 | 0 | $connection->proto_send(protobit => "set_tool_versions", protodata => \%protodata, nopause => 1); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 290 | } elsif($server) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 291 | 0 | $connection->proto_send(protobit => "host_versions", protodata => \%protodata, nopause => 1); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 292 | } else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 293 | 0 | $connection->proto_send(protobit => "set_service_versions", protodata => \%protodata, nopause => 1); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 294 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 295 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 296 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 297 | # keys(%foo) in void context, the standard way of reseting | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 298 | # a hash iterator, appears to leak memory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 299 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 300 | 0 | ▶ | sub hash_iter_reset($) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
hash_iter_reset: not called CC=2 SCAR=17.9
Pod
undocumented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 301 | 0 | ▶ | while((undef, undef) = each(%{$_[0]})) {} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 302 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 303 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 304 | 5 | 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||