line |
true |
false |
branch |
28
|
1 |
1 |
ref $_[0] ? : |
34
|
165 |
97 |
ref $self ? : |
47
|
4 |
43 |
if (@_ and not $new->open(@_)) |
55
|
25 |
19 |
if (scalar(@_) % 2) |
56
|
25 |
19 |
unless defined $self->{'openoptions'} |
58
|
0 |
44 |
if (defined $self->{'fh'}) |
64
|
1 |
43 |
if ($options{'name'} eq '-') { } |
65
|
1 |
0 |
if (defined $options{'fh'}) { } |
76
|
43 |
0 |
unless ($options{'readonly'}) |
77
|
39 |
4 |
if ($fh->open($options{'name'}, 2)) { } |
83
|
4 |
39 |
unless ($ok) |
84
|
0 |
4 |
if ($fh->open($options{'name'}, 0)) { } |
90
|
4 |
39 |
unless ($ok) |
96
|
1 |
39 |
if $SEEK_VIA_READ |
99
|
39 |
1 |
unless $external_fh |
110
|
0 |
11 |
unless (defined $self->{'fh'}) |
121
|
0 |
1747 |
unless my $fh = $self->{'fh'} |
123
|
18 |
1729 |
if (defined $result and defined $self->{'tell'}) |
131
|
10 |
71 |
if (defined $self->{'tell'}) |
140
|
2 |
0 |
if (defined $self->{'filename'}) |
142
|
2 |
0 |
if defined $self->{'fh'} |
143
|
0 |
2 |
unless (unlink $filename) |
155
|
0 |
5 |
unless (defined $filename) |
159
|
0 |
5 |
if (-f $filename) |
164
|
3 |
2 |
unless defined $perms |
166
|
0 |
5 |
unless $fh->open($filename, 'w+', $perms) |
178
|
0 |
1646 |
unless (defined $header_len and defined $record_len) |
182
|
0 |
1646 |
unless (defined $num) |
193
|
0 |
0 |
unless defined(my $offset = $self->get_record_offset($num)) |
199
|
0 |
1676 |
unless (defined $self->{'fh'}) |
203
|
0 |
1676 |
unless ($self->{'fh'}->seek($offset, 0)) |
211
|
0 |
3 |
unless (defined $self->{'fh'}) |
216
|
0 |
3 |
if ($offset < $tell) |
220
|
1 |
2 |
if ($offset > $tell) |
225
|
0 |
3 |
if ($tell != $offset) |
233
|
1 |
12 |
if ($_[0]) { } |
246
|
0 |
1604 |
unless (defined $num) |
250
|
2 |
1602 |
if ($self->last_record > 0 and $num > $self->last_record) |
254
|
1588 |
14 |
unless (defined $in_length) |
257
|
14 |
1588 |
if ($in_length < 0) |
261
|
0 |
1602 |
unless defined(my $offset = $self->get_record_offset($num)) |
266
|
0 |
1602 |
unless (defined $offset) |
270
|
0 |
1602 |
unless $self->seek_to($offset) |
272
|
14 |
1588 |
if $length < 0 |
275
|
0 |
1602 |
if (not defined $read or $in_length > 0 and $read != $in_length) |
285
|
0 |
44 |
unless defined(my $offset = $self->get_record_offset($num)) |
286
|
0 |
44 |
unless defined $self->write_to($offset, @_) |
287
|
3 |
41 |
$num == 0 ? : |
292
|
0 |
77 |
unless ($self->{'rw'}) |
296
|
0 |
77 |
unless $self->seek_to($offset) |
299
|
0 |
77 |
unless ($self->{'fh'}->print(@_)) |
302
|
13 |
64 |
$offset == 0 ? : |