Branch Coverage

blib/lib/Image/ExifTool/SigmaRaw.pm
Criterion Covered Total %
branch 87 148 58.7


line true false branch
279 118 690 unless $chars->[$i]
299 2 0 if (length($$dataPt) - $hdrLen >= 160)
301 0 2 if ($verbose)
310 44 20 unless $tags[$i]
335 0 2 unless ($size >= 24 and $$dataPt =~ /^SECp/)
340 0 2 unless ($size >= 24 + 8 * $entries + $len)
344 0 2 if $verbose
345 0 2 unless $fmt == 0
351 0 59 if ($namePos >= @chars or $valPos >= @chars)
357 0 0 if (not $tagTablePtr->{$tag} and $unknown and $tag =~ /^\w+$/)
390 0 1 unless $raf->Seek($dirInfo->{'DirStart'}, 0)
393 0 1 unless $raf->Read($hdr, 12) == 12
394 0 1 unless $hdr =~ /^SECd/
398 0 1 unless $entries > 2 and $entries < 20
400 0 1 unless ($raf->Read($dir, $entries * 12) == $entries * 12)
409 1 4 if not defined $outPos or $outPos > $offset
411 0 5 if defined $order{$offset}
415 0 1 unless ($raf->Seek(0, 0) and $raf->Read($buff, $outPos) == $outPos)
418 0 1 unless &Write($outfile, $buff)
429 0 1 if ($order{'BAD'}) { }
442 0 5 unless $raf->Seek($offset, 0)
444 3 2 if ($tag eq 'IMA2' and $len > 28) { }
446 0 3 unless $raf->Read($buff, 28) == 28
447 0 3 unless &Write($outfile, $buff)
451 2 1 if ($buff =~ /^SECi\0\0\x02\0\x02\0\0\0\x12\0\0\0/) { }
452 0 2 unless $raf->Read($buff, $len) == $len
453 1 1 if ($buff =~ /^\xff\xd8\xff\xe1/) { }
470 0 1 unless $success and $newData
471 0 1 if $success < 0
473 0 1 unless $newData =~ /^\xff\xd8\xff\xe1/
477 1 0 $et->{'CHANGED'} ? :
478 0 1 unless &Write($outfile, $$outPt)
483 0 1 unless &Write($outfile, $buff)
487 0 1 unless &Image::ExifTool::CopyBlock($raf, $outfile, $len)
492 0 2 unless &Image::ExifTool::CopyBlock($raf, $outfile, $len)
496 1 4 if ($len & 3)
498 0 1 unless &Write($outfile, scalar "\0" x $pad)
506 0 1 unless $didContain
508 0 1 unless &Write($outfile, $hdr, $dir, pack("V", $outPos))
522 0 2 unless $raf->Seek($dirInfo->{'DirStart'}, 0)
526 0 2 unless $raf->Read($buff, 12) == 12
527 0 2 unless $buff =~ /^SECd/
529 0 2 if $verbose
530 0 2 unless $raf->Read($dir, $entries * 12) == $entries * 12
535 0 10 if ($verbose)
537 0 0 if ($verbose > 2)
538 0 0 unless $raf->Seek($offset, 0)
539 0 0 unless $raf->Read($buff, $len) == $len
543 2 8 unless $tagInfo
544 0 8 unless $raf->Seek($offset, 0)
545 6 2 if ($tagInfo->{'Name'} eq 'PreviewImage') { }
547 0 6 unless $raf->Read($buff, 28) == 28
551 4 2 unless ($buff =~ /^SECi\0\0\x02\0\x02\0\0\0\x12\0\0\0/)
553 0 4 if ($et->{'ImageDataMD5'} and substr($buff, 8, 1) ne "\2")
558 0 2 unless $raf->Read($buff, $len) == $len
560 1 1 if ($buff =~ /^\xff\xd8\xff\xe1/)
566 0 2 unless $raf->Read($buff, $len) == $len
569 2 2 if ($subdir) { }
575 1 1 if ($tagInfo->{'Name'} eq "JpgFromRaw")
600 1 2 $outfile ? :
603 0 3 unless $raf->Read($buff, 40) == 40
604 0 3 unless $buff =~ /^FOVb/
612 0 3 if ($ver > 5)
616 3 0 if ($ver > 2)
618 0 3 if ($ver >= 4) { }
622 2 1 $ver > 2.2 ? :
626 0 3 unless ($raf->Read($buf2, $more) == $more)
632 3 0 $ver < 4 ? :
635 2 1 unless ($outfile)
642 0 3 unless $raf->Seek(-4, 2)
643 0 3 unless ($raf->Read($buff, 4) == 4)
652 1 2 if ($outfile) { }
655 0 1 if $err and $err eq -1
660 0 3 if $err