line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::WebSocket::X::BadHeader; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
424
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
35
|
|
4
|
1
|
|
|
1
|
|
4
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
22
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
4
|
use parent qw( Net::WebSocket::X::Base ); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
5
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub _new { |
9
|
3
|
|
|
3
|
|
198
|
my ($class, $name => $value, $why) = @_; |
10
|
|
|
|
|
|
|
|
11
|
3
|
|
|
|
|
7
|
my @args = ( |
12
|
|
|
|
|
|
|
name => $name, |
13
|
|
|
|
|
|
|
value => $value, |
14
|
|
|
|
|
|
|
why => $why, |
15
|
|
|
|
|
|
|
); |
16
|
|
|
|
|
|
|
|
17
|
3
|
50
|
|
|
|
5
|
my $value_str = defined($value) ? $value : q<>; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
#Perl 5.10 still warns on length(undef) |
20
|
3
|
100
|
66
|
|
|
16
|
my $str = defined($why) && length($why) ? "Bad “$name” header ($value_str): $why" : "Bad “$name” header ($value_str)"; |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
9
|
return $class->SUPER::_new( $str, @args ); |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
1; |