| 1 | package Langertha::Holmgang::Sim::Linux::Postfix; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 2 | # ABSTRACT: Postfix on a simulated Linux server — postconf, postmap, newaliases, queue | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 3 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 4 | 2 | ▶ | use strict; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 5 | 2 | ▶ | use warnings; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 6 | 2 | ▶ | use utf8; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 7 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 8 | 2 | our $VERSION = '0.001'; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 9 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 10 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 11 | 23 | ▶ | sub _lx { 'Langertha::Holmgang::Sim::Linux' } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_lx: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 12 | 11 | ▶ | sub _text { _lx()->can('_file_text')->(@_) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_text: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 13 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 14 | 2 | my $MAIN = '/etc/postfix/main.cf'; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 15 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 16 | 2 | our %DEFAULT = ( | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 17 | myhostname => 'mail.example.com', mydomain => 'example.com', myorigin => '$myhostname', mydestination => '$myhostname, localhost.$mydomain, localhost', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 18 | relayhost => '', mynetworks => '127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128', mynetworks_style => 'host', inet_interfaces => 'all', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 19 | inet_protocols => 'all', message_size_limit => '10240000', mailbox_size_limit => '51200000', smtpd_relay_restrictions => | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 20 | 'permit_mynetworks, permit_sasl_authenticated, defer_unauth_destination', smtpd_recipient_restrictions => '', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 21 | smtp_sasl_auth_enable => 'no', smtp_sasl_password_maps => '', smtp_sasl_security_options => 'noplaintext, noanonymous', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 22 | smtp_tls_security_level => '', smtpd_tls_security_level => '', transport_maps => '', relay_domains => '', virtual_alias_maps => '', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 23 | virtual_alias_domains => '$virtual_alias_maps', alias_maps => 'hash:/etc/aliases', alias_database => 'hash:/etc/aliases', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 24 | sender_canonical_maps => '', recipient_delimiter => '', compatibility_level => '0', maximal_queue_lifetime => '5d', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 25 | bounce_queue_lifetime => '5d', smtpd_banner => '$myhostname ESMTP $mail_name', smtp_tls_CAfile => '', smtpd_sasl_auth_enable => 'no', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 26 | header_size_limit => '102400', default_destination_concurrency_limit => '20', smtp_tls_wrappermode => 'no', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 27 | ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 28 | 2 | my %NUMERIC = map { $_ => 1 } qw( message_size_limit mailbox_size_limit header_size_limit default_destination_concurrency_limit ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 29 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 30 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 31 | 6 | ▶ | sub parse_main { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
parse_main: called CC=8 SCAR=24.0
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 32 | 6 | my ($text) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 33 | 6 | my ( %p, $cur ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 34 | 6 | ▶ | for my $l ( split /\n/, $text // '' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$text // ""
MC/DC0%0/1
$text // ""
$text
Truth table50%1/2
A
A= $text
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 35 | 27 | ▶ | next if $l =~ /\A\s*(?:#|\z)/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 36 | 0 | ▶ | if ( $l =~ /\A\s/ && defined $cur ) { $p{$cur} .= ' ' . ( $l =~ s/\A\s+|\s+\z//gr ); next } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
$l =~ /\A\s/ and defined $cur
MC/DC0%0/2
$l =~ /\A\s/ and defined $cur
$l =~ /\A\s/
defined $cur
Truth table33%1/3
A and B
A= $l =~ /\A\s/B= defined $cur
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 37 | 27 | ▶ | if ( $l =~ /\A([A-Za-z0-9_]+)\s*=\s*(.*?)\s*\z/ ) { ( $cur, $p{$1} ) = ( $1, $2 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 38 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 39 | 6 | s/\s+/ /g for values %p; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 40 | 6 | return \%p; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 41 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 42 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 43 | 4 | ▶ | sub _check { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_check: called CC=3 SCAR=11.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 44 | 4 | my ($p) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 45 | 4 | for my $k ( sort grep { $NUMERIC{$_} } keys %$p ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 46 | 3 | ▶ | return "/usr/sbin/postconf: fatal: bad numerical configuration: $k = $p->{$k}" unless $p->{$k} =~ /\A\d+\z/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 47 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 48 | 2 | return undef; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 49 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 50 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 51 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 52 | 1 | ▶ | sub prepare { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
prepare: called CC=3 SCAR=12.0
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 53 | 1 | my ( $dev, $ctx ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 54 | 1 | ▶ | my $pf = $dev->{postfix} or return; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 55 | 1 | ▶ | $pf->{running} //= parse_main( _text( $dev, $MAIN ) ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition33%1/3
$$pf{"running"} //= parse_main(_text($dev, $MAIN))
MC/DC0%0/2
$$pf{"running"} //= parse_main(_text($dev, $MAIN))
$$pf{"running"}
parse_main(_text($dev, $MAIN))
Truth table33%1/3
A //= B
A= $$pf{"running"}B= parse_main(_text($dev, $MAIN))
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 56 | 1 | return; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 57 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 58 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 59 | 4 | ▶ | sub _reload { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_reload: called CC=2 SCAR=6.9
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 60 | 4 | my ($dev) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 61 | 4 | my $p = parse_main( _text( $dev, $MAIN ) ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 62 | 4 | ▶ | if ( my $e = _check($p) ) { return ( $e, 0 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 63 | 2 | $dev->{postfix}{running} = $p; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 64 | 2 | return ( '', 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 65 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 66 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 67 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 68 | 2 | ▶ | sub service_event { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
service_event: called CC=3 SCAR=11.0
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 69 | 2 | my ( $dev, $verb ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 70 | 2 | ▶ | return if $verb eq 'stop'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 71 | 2 | my ( $e, $ok ) = _reload($dev); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 72 | 2 | ▶ | die "Job for postfix.service failed because the control process exited with error code.\n$e\n" unless $ok; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 73 | 1 | return; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 74 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 75 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 76 | 7 | ▶ | sub _running { my $s = ( $_[0]{services} || {} )->{postfix}; return $s && $s->{active} ? 1 : 0 } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_running: called CC=4 SCAR=16.9
Branch: 1 branch
Condition40%2/5
$_[0]{'services'} || {}
$s and $$s{"active"}
MC/DC0%0/1
$_[0]{'services'} || {}
$_[0]{'services'}
MC/DC0%0/2
$s and $$s{"active"}
$s
$$s{"active"}
Truth table50%1/2
A
A= $_[0]{'services'}
Truth table33%1/3
A and B
A= $sB= $$s{"active"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 77 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 78 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 79 | 4 | ▶ | sub postconf { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postconf: called CC=31 SCAR=44.8
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 80 | 4 | my ( $dev, $av ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 81 | 4 | my @a = @$av; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 82 | 4 | my %f; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 83 | my @n; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 84 | 4 | ▶ | while (@a) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 85 | 8 | my $x = shift @a; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 86 | 8 | ▶ | if ( $x =~ /\A-([ndhexX]+)\z/ ) { $f{$_} = 1 for split //, $1 } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 87 | 0 | elsif ( $x =~ /\A-[cM F P]/ ) { return ( '', 0 ) } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 88 | 4 | else { push @n, $x } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 89 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 90 | 4 | ▶ | my $text = _text( $dev, $MAIN ) // ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
_text($dev, $MAIN) // ""
MC/DC0%0/1
_text($dev, $MAIN) // ""
_text($dev, $MAIN)
Truth table50%1/2
A
A= _text($dev, $MAIN)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 91 | 4 | ▶ | if ( $f{e} ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 92 | 3 | my @lines = split /\n/, $text, -1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 93 | 3 | ▶ | pop @lines if @lines && $lines[-1] eq ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
@lines and $lines[-1] eq ""
MC/DC0%0/2
@lines and $lines[-1] eq ""
@lines
$lines[-1] eq ""
Truth table33%1/3
A and B
A= @linesB= $lines[-1] eq ""
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 94 | 3 | for my $kv (@n) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 95 | 3 | ▶ | my ( $k, $v ) = $kv =~ /\A\s*([A-Za-z0-9_]+)\s*=\s*(.*?)\s*\z/ or return ( "postconf: fatal: invalid parameter assignment: $kv", 0 ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 96 | 3 | my $done; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 97 | 3 | ▶ | for ( my $i = 0; $i < @lines; $i++ ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 98 | 11 | ▶ | next unless $lines[$i] =~ /\A\Q$k\E\s*=/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 99 | 2 | my $j = $i + 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 100 | 2 | ▶ | $j++ while $j < @lines && $lines[$j] =~ /\A\s+\S/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition66%2/3
$j < @lines and $lines[$j] =~ /\A\s+\S/
MC/DC0%0/2
$j < @lines and $lines[$j] =~ /\A\s+\S/
$j < @lines
$lines[$j] =~ /\A\s+\S/
Truth table66%2/3
A and B
A= $j < @linesB= $lines[$j] =~ /\A\s+\S/
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 101 | 2 | splice @lines, $i, $j - $i, "$k = $v"; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 102 | 2 | $done = 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 103 | 2 | last; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 104 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 105 | 3 | ▶ | push @lines, "$k = $v" unless $done; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 106 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 107 | 3 | _lx()->can('_file_set')->( $dev, $MAIN, join( "\n", @lines ) . "\n" ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 108 | 3 | return ( '', 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 109 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 110 | 1 | ▶ | if ( $f{X} ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 111 | 0 | my @lines = split /\n/, $text; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 112 | 0 | my @out; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 113 | 0 | ▶ | for ( my $i = 0; $i < @lines; $i++ ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 114 | 0 | ▶ | if ( grep { $lines[$i] =~ /\A\Q$_\E\s*=/ } @n ) { $i++ while $i + 1 < @lines && $lines[ $i + 1 ] =~ /\A\s+\S/; next } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
Condition0%0/3
$i + 1 < @lines and $lines[$i + 1] =~ /\A\s+\S/
MC/DC0%0/2
$i + 1 < @lines and $lines[$i + 1] =~ /\A\s+\S/
$i + 1 < @lines
$lines[$i + 1] =~ /\A\s+\S/
Truth table0%0/3
A and B
A= $i + 1 < @linesB= $lines[$i + 1] =~ /\A\s+\S/
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 115 | 0 | push @out, $lines[$i]; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 116 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 117 | 0 | _lx()->can('_file_set')->( $dev, $MAIN, join( "\n", @out ) . "\n" ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 118 | 0 | return ( '', 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 119 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 120 | 1 | my $p = parse_main($text); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 121 | 1 | ▶ | my %all = $f{d} ? %DEFAULT : $f{n} ? %$p : ( %DEFAULT, %$p ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 122 | 1 | ▶ | my @show = @n ? @n : sort keys %all; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 123 | 1 | my ( @l, $ok ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 124 | 1 | $ok = 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 125 | 1 | for my $k (@show) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 126 | 0 | ▶ | if ( !exists $all{$k} && !exists $DEFAULT{$k} ) { push @l, "postconf: warning: $k: unknown parameter"; $ok = 0; next } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
exists $all{$k} or exists $Langertha::Holmgang::Sim::Linux::Postfix::DEFAULT{$k}
MC/DC0%0/2
exists $all{$k} or exists $Langertha::Holmgang::Sim::Linux::Postfix::DEFAULT{$k}
exists $all{$k}
exists $Langertha::Holmgang::Sim::Linux::Postfix::DEFAULT{$k}
Truth table33%1/3
A or B
A= exists $all{$k}B= exists $Langertha::Holmgang::Sim::Linux::Postfix::DEFAULT{$k}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 127 | 1 | ▶ | my $v = exists $all{$k} ? $all{$k} : $DEFAULT{$k}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 128 | 1 | ▶ | next if $f{n} && !exists $p->{$k}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
$f{"n"} and not exists $$p{$k}
MC/DC0%0/2
$f{"n"} and not exists $$p{$k}
$f{"n"}
not exists $$p{$k}
Truth table33%1/3
A and not(B)
A= $f{"n"}B= not exists $$p{$k}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 129 | 1 | ▶ | push @l, $f{h} ? $v : "$k = $v"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 130 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 131 | 1 | return ( join( "\n", @l ), $ok ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 132 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 133 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 134 | 3 | ▶ | sub _flush { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_flush: called CC=12 SCAR=25.9
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 135 | 3 | my ( $dev, $only ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 136 | 3 | my $pf = $dev->{postfix}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 137 | 3 | my @keep; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 138 | 3 | ▶ | for my $m ( @{ $pf->{queue} || [] } ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$pf{'queue'} || []
MC/DC0%0/1
$$pf{'queue'} || []
$$pf{'queue'}
Truth table50%1/2
A
A= $$pf{'queue'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 139 | 6 | ▶ | my $go = ( $m->{queue} // q{deferred} ) ne q{hold} && ( !defined $only || $m->{id} eq $only ) && $m->{deliver_when}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition45%5/11
($$m{'queue'} // 'deferred') ne 'hold' && (!defined($only) || $$m{'id'} eq $only) && $$m{'deliver_when'}
($$m{"queue"} // "deferred") ne "hold" and !defined($only) || $$m{"id"} eq $only
$$m{"queue"} // "deferred"
not defined $only or $$m{"id"} eq $only
MC/DC0%0/4
($$m{'queue'} // 'deferred') ne 'hold' && (!defined($only) || $$m{'id'} eq $only) && $$m{'deliver_when'}
$$m{"queue"}
not defined $only
$$m{"id"} eq $only
$$m{'deliver_when'}
Truth table0%0/6
A and not(B) or C && D
A= $$m{"queue"}B= not defined $onlyC= $$m{"id"} eq $onlyD= $$m{'deliver_when'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 140 | 6 | ▶ | if ($go) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 141 | 3 | ▶ | for my $c ( @{ $m->{deliver_when} || [] } ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$m{'deliver_when'} || []
MC/DC0%0/1
$$m{'deliver_when'} || []
$$m{'deliver_when'}
Truth table50%1/2
A
A= $$m{'deliver_when'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 142 | 5 | my ($ok) = _lx()->can('_condition')->( $dev, $c ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 143 | 5 | ▶ | $go = 0, last unless $ok; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 144 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 145 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 146 | 6 | ▶ | if ($go) { push @{ $pf->{delivered} }, $m->{id} } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 147 | 5 | else { push @keep, $m } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 148 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 149 | 3 | $pf->{queue} = \@keep; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 150 | 3 | return; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 151 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 152 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 153 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 154 | 2 | ▶ | sub postfix { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postfix: called CC=14 SCAR=43.8
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 155 | 2 | my ( $dev, $av ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 156 | 2 | ▶ | my $verb = $av->[0] // ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$av[0] // ""
MC/DC0%0/1
$$av[0] // ""
$$av[0]
Truth table50%1/2
A
A= $$av[0]
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 157 | 2 | ▶ | if ( $verb eq 'check' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 158 | 0 | my $e = _check( parse_main( _text( $dev, $MAIN ) ) ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 159 | 0 | ▶ | return defined $e ? ( $e, 0 ) : ( '', 1 ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 160 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 161 | 2 | ▶ | if ( $verb eq 'reload' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 162 | 2 | ▶ | return ( 'postfix/postfix-script: fatal: the Postfix mail system is not running', 0 ) unless _running($dev); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 163 | 2 | my ( $e, $ok ) = _reload($dev); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 164 | 2 | ▶ | return ( $e, 0 ) unless $ok; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 165 | 1 | return ( 'postfix/postfix-script: refreshing the Postfix mail system', 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 166 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 167 | 0 | ▶ | if ( $verb eq 'status' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 168 | 0 | ▶ | return _running($dev) ? ( 'postfix/postfix-script: the Postfix mail system is running: PID: 1342', 1 ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 169 | : ( 'postfix/postfix-script: the Postfix mail system is not running', 1 ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 170 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 171 | 0 | ▶ | if ( $verb eq 'flush' ) { _flush($dev) if _running($dev); return ( '', 1 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 172 | 0 | ▶ | if ( $verb eq 'start' || $verb eq 'stop' || $verb eq 'restart' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/6
$verb eq "start" or $verb eq "stop" or $verb eq "restart"
$verb eq "start" or $verb eq "stop"
MC/DC0%0/3
$verb eq "start" or $verb eq "stop" or $verb eq "restart"
$verb eq "start"
$verb eq "stop"
$verb eq "restart"
Truth table0%0/4
A or B or C
A= $verb eq "start"B= $verb eq "stop"C= $verb eq "restart"
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 173 | 0 | return _lx()->can('_systemctl')->( $dev, [ $verb, 'postfix' ], {} ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 174 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 175 | 0 | return ( "postfix: fatal: unknown command: '$verb'. Usage: postfix start (or stop, reload, abort, flush, check, status, set-permissions, upgrade-configuration)", 0 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 176 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 177 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 178 | 2 | ▶ | sub _build_db { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_build_db: called CC=12 SCAR=25.8
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 179 | 2 | my ( $dev, $src, $prog ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 180 | 2 | my $e = _lx()->can('_file_entry')->( $dev, $src ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 181 | 2 | ▶ | return ( "$prog: fatal: open $src: No such file or directory", 0 ) unless $e; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 182 | 2 | ▶ | my $text = _text( $dev, $src ) // ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
_text($dev, $src) // ""
MC/DC0%0/1
_text($dev, $src) // ""
_text($dev, $src)
Truth table50%1/2
A
A= _text($dev, $src)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 183 | 2 | my @w; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 184 | 2 | my $n = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 185 | 2 | for my $l ( split /\n/, $text ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 186 | 3 | $n++; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 187 | 3 | ▶ | next if $l =~ /\A\s*(?:#|\z)/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 188 | 3 | ▶ | next if $l =~ /\A\s/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 189 | 3 | ▶ | my $ok = $prog eq 'postalias' ? $l =~ /\A\S+?:\s*\S/ : $l =~ /\A\S+\s+\S/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 190 | 3 | ▶ | push @w, $prog eq 'postalias' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 191 | ? "postalias: warning: $src, line $n: need name:value pair" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 192 | : "postmap: warning: $src, line $n: expected format: key whitespace value" unless $ok; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 193 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 194 | 2 | ▶ | my %db = ( content => $text, owner => $e->{owner} // 'root', group => $e->{group} // 'root', mode => $e->{mode} // '0644' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition100%6/6
$$e{"owner"} // "root"
$$e{"group"} // "root"
$$e{"mode"} // "0644"
MC/DC100%1/1
$$e{"owner"} // "root"
$$e{"owner"}
MC/DC100%1/1
$$e{"group"} // "root"
$$e{"group"}
MC/DC100%1/1
$$e{"mode"} // "0644"
$$e{"mode"}
Truth table100%2/2
A
A= $$e{"owner"}
Truth table100%2/2
A
A= $$e{"group"}
Truth table100%2/2
A
A= $$e{"mode"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 195 | 2 | $dev->{files}{"$src.db"} = \%db; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 196 | 2 | return ( join( "\n", @w ), 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 197 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 198 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 199 | 4 | ▶ | sub _map_arg { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_map_arg: called CC=2 SCAR=6.9
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 200 | 4 | my ($a) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 201 | 4 | my ( $type, $f ) = $a =~ /\A(?:(\w+):)?(.+)\z/; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 202 | 4 | ▶ | return ( $type // 'hash', $f ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition100%2/2
$type // "hash"
MC/DC100%1/1
$type // "hash"
$type
Truth table100%2/2
A
A= $type
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 203 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 204 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 205 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 206 | 4 | ▶ | sub postmap { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postmap: called CC=19 SCAR=30.9
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 207 | 4 | my ( $dev, $av, $ctx, $prog ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 208 | 4 | ▶ | $prog //= 'postmap'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition100%2/2
$prog //= "postmap"
MC/DC100%1/1
$prog //= "postmap"
$prog
Truth table100%2/2
A
A= $prog
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 209 | 4 | my @a = @$av; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 210 | 4 | my ( $q, @files ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 211 | 4 | ▶ | while (@a) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 212 | 5 | my $x = shift @a; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 213 | 5 | ▶ | if ( $x eq '-q' ) { $q = shift @a } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 214 | elsif ( $x =~ /\A-/ ) { } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 215 | 3 | else { push @files, $x } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 216 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 217 | 4 | ▶ | if ( $prog eq 'newaliases' ) { @files = ('/etc/aliases'); $prog = 'postalias' } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 218 | 4 | ▶ | return ( "$prog: fatal: usage: $prog [-Nfinoprsuvw] [-c config_dir] [-d key] [-q key] [map_type:]file...", 0 ) unless @files; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 219 | 4 | ▶ | if ( defined $q ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 220 | 2 | my ( $type, $f ) = _map_arg( $files[0] ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 221 | 2 | my $db = _lx()->can('_file_entry')->( $dev, "$f.db" ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 222 | 2 | ▶ | return ( "$prog: fatal: open database $f.db: No such file or directory", 0 ) unless $db; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 223 | # eine mit postalias gebaute Tabelle (Aliase) hat Schlüssel ohne Doppelpunkt — gleich, wer nachschlägt | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 224 | 1 | ▶ | my $alias = $prog eq 'postalias' || $f =~ m{(?:\A|/)aliases\z}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition33%1/3
$prog eq 'postalias' || $f =~ m[(?:\A|/)aliases\z]
MC/DC0%0/2
$prog eq 'postalias' || $f =~ m[(?:\A|/)aliases\z]
$prog eq 'postalias'
$f =~ m[(?:\A|/)aliases\z]
Truth table33%1/3
A || B
A= $prog eq 'postalias'B= $f =~ m[(?:\A|/)aliases\z]
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 225 | 1 | ▶ | for my $l ( split /\n/, $db->{content} // '' ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$db{"content"} // ""
MC/DC0%0/1
$$db{"content"} // ""
$$db{"content"}
Truth table50%1/2
A
A= $$db{"content"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 226 | 1 | ▶ | next if $l =~ /\A\s*(?:#|\z)/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 227 | 1 | ▶ | my ( $k, $v ) = $alias ? $l =~ /\A(\S+?):\s*(.*?)\s*\z/ : $l =~ /\A(\S+)\s+(.*?)\s*\z/; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 228 | 1 | ▶ | return ( $v, 1 ) if defined $k && lc $k eq lc $q; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
defined $k and lc $k eq lc $q
MC/DC0%0/2
defined $k and lc $k eq lc $q
defined $k
lc $k eq lc $q
Truth table33%1/3
A and B
A= defined $kB= lc $k eq lc $q
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 229 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 230 | 0 | return ( '', 0 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 231 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 232 | 2 | my @out; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 233 | 2 | for my $fa (@files) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 234 | 2 | my ( $type, $f ) = _map_arg($fa); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 235 | 2 | my ( $o, $ok ) = _build_db( $dev, $f, $prog ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 236 | 2 | ▶ | push @out, $o if length $o; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 237 | 2 | ▶ | return ( join( "\n", @out ), 0 ) unless $ok; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 238 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 239 | 2 | return ( join( "\n", @out ), 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 240 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 241 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 242 | 2 | ▶ | sub _queue_text { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
_queue_text: called CC=18 SCAR=33.5
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 243 | 2 | my ($dev) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 244 | 2 | ▶ | my @q = @{ $dev->{postfix}{queue} || [] }; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$dev{'postfix'}{'queue'} || []
MC/DC0%0/1
$$dev{'postfix'}{'queue'} || []
$$dev{'postfix'}{'queue'}
Truth table50%1/2
A
A= $$dev{'postfix'}{'queue'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 245 | 2 | ▶ | return 'Mail queue is empty' unless @q; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 246 | 1 | my @l = ('-Queue ID- --Size-- ----Arrival Time---- -Sender/Recipient-------'); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 247 | 1 | my $sum = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 248 | 1 | for my $m (@q) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 249 | 1 | ▶ | my $mark = ( $m->{queue} // '' ) eq 'hold' ? '!' : ( $m->{queue} // '' ) eq 'active' ? '*' : ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
Condition50%2/4
$$m{"queue"} // ""
$$m{"queue"} // ""
MC/DC0%0/1
$$m{"queue"} // ""
$$m{"queue"}
MC/DC0%0/1
$$m{"queue"} // ""
$$m{"queue"}
Truth table50%1/2
A
A= $$m{"queue"}
Truth table50%1/2
A
A= $$m{"queue"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 250 | 1 | ▶ | push @l, sprintf( '%-11s %8d %s %s', $m->{id} . $mark, $m->{size} // 1024, $m->{time} // 'Tue Oct 20 08:00:00', length( $m->{from} // '' ) ? $m->{from} : 'MAILER-DAEMON' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition50%3/6
$$m{"size"} // 1024
$$m{"time"} // "Tue Oct 20 08:00:00"
$$m{"from"} // ""
MC/DC0%0/1
$$m{"size"} // 1024
$$m{"size"}
MC/DC0%0/1
$$m{"time"} // "Tue Oct 20 08:00:00"
$$m{"time"}
MC/DC0%0/1
$$m{"from"} // ""
$$m{"from"}
Truth table50%1/2
A
A= $$m{"size"}
Truth table50%1/2
A
A= $$m{"time"}
Truth table50%1/2
A
A= $$m{"from"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 251 | 1 | ▶ | push @l, " ($m->{reason})" if defined $m->{reason} && ( $m->{queue} // 'deferred' ) eq 'deferred'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition40%2/5
defined $$m{"reason"} and ($$m{"queue"} // "deferred") eq "deferred"
$$m{"queue"} // "deferred"
MC/DC0%0/2
defined $$m{"reason"} and ($$m{"queue"} // "deferred") eq "deferred"
defined $$m{"reason"}
$$m{"queue"}
Truth table33%1/3
A and B
A= defined $$m{"reason"}B= $$m{"queue"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 252 | 1 | ▶ | push @l, map {" $_"} @{ $m->{to} || [] }; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$m{'to'} || []
MC/DC0%0/1
$$m{'to'} || []
$$m{'to'}
Truth table50%1/2
A
A= $$m{'to'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 253 | 1 | push @l, ''; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 254 | 1 | ▶ | $sum += $m->{size} // 1024; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$m{"size"} // 1024
MC/DC0%0/1
$$m{"size"} // 1024
$$m{"size"}
Truth table50%1/2
A
A= $$m{"size"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 255 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 256 | 1 | ▶ | push @l, sprintf( '-- %d Kbytes in %d Request%s.', int( $sum / 1024 + 0.999 ), scalar @q, @q == 1 ? '' : 's' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 257 | 1 | return join "\n", @l; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 258 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 259 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 260 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 261 | 5 | ▶ | sub postqueue { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postqueue: called CC=8 SCAR=27.2
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 262 | 5 | my ( $dev, $av ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 263 | 5 | my @a = @$av; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 264 | 5 | ▶ | return ( "postqueue: fatal: Queue report unavailable - mail system is down", 0 ) unless _running($dev); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 265 | 5 | ▶ | my $o = shift(@a) // ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
shift @a // ""
MC/DC0%0/1
shift @a // ""
shift @a
Truth table50%1/2
A
A= shift @a
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 266 | 5 | ▶ | return ( _queue_text($dev), 1 ) if $o eq '-p' || $o eq ''; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition66%2/3
$o eq "-p" or $o eq ""
MC/DC50%1/2
$o eq "-p" or $o eq ""
$o eq "-p"
$o eq ""
Truth table66%2/3
A or B
A= $o eq "-p"B= $o eq ""
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 267 | 3 | ▶ | if ( $o eq '-f' ) { _flush($dev); return ( '', 1 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 268 | 0 | ▶ | if ( $o eq '-i' ) { _flush( $dev, shift @a ); return ( '', 1 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 269 | 0 | ▶ | if ( $o eq '-j' ) { return ( '', 1 ) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 270 | 0 | return ( 'postqueue: fatal: usage: postqueue -f | postqueue -i queueid | postqueue -j | postqueue -p | postqueue -s site', 0 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 271 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 272 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 273 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 274 | 1 | ▶ | sub postsuper { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postsuper: called CC=24 SCAR=41.3
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 275 | 1 | my ( $dev, $av, $ctx, $stdin ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 276 | 1 | my @a = @$av; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 277 | 1 | my $pf = $dev->{postfix}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 278 | 1 | my ( %act, $n ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 279 | 1 | ▶ | while (@a) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 280 | 1 | my $x = shift @a; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 281 | 1 | ▶ | if ( $x =~ /\A-([dhHr])\z/ ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 282 | 1 | ▶ | my $id = shift @a // return ( "postsuper: fatal: usage: postsuper [-c config_dir] [-d queue_id (delete)] [-h queue_id (hold)] [-H queue_id (un-hold)] [-p (purge temporary files)] [-r queue_id (requeue)] [-s (structure fix)] [-S (structure fix)] [-v (verbose)] [queue...]", 0 ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
shift @a // (return "postsuper: fatal: usage: postsuper [-c config_dir] [-d queue_id (delete)] [-h queue_id (hold)] [-H queue_id (un-hold)] [-p (purge temporary files)] [-r queue_id (requeue)] [-s (structure fix)] [-S (structure fix)] [-v (verbose)] [queue...]", 0)
MC/DC0%0/1
shift @a // (return "postsuper: fatal: usage: postsuper [-c config_dir] [-d queue_id (delete)] [-h queue_id (hold)] [-H queue_id (un-hold)] [-p (purge temporary files)] [-r queue_id (requeue)] [-s (structure fix)] [-S (structure fix)] [-v (verbose)] [queue...]", 0)
shift @a
Truth table50%1/2
A
A= shift @a
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 283 | 1 | ▶ | push @{ $act{$1} }, $id eq '-' ? ( split ' ', $stdin // '' ) : $id; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/2
$stdin // ""
MC/DC0%0/1
$stdin // ""
$stdin
Truth table0%0/2
A
A= $stdin
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 284 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 285 | 0 | elsif ( $x =~ /\A(?:deferred|hold|active|incoming|maildrop)\z/ ) { $act{queue} = $x } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 286 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 287 | 1 | my @l; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 288 | 1 | for my $op (qw( d h H r )) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 289 | 4 | ▶ | my @ids = @{ $act{$op} || [] } or next; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition100%2/2
$act{$op} || []
MC/DC100%1/1
$act{$op} || []
$act{$op}
Truth table100%2/2
A
A= $act{$op}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 290 | 1 | my $all = grep { $_ eq 'ALL' } @ids; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 291 | 1 | my %want = map { $_ => 1 } @ids; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 292 | 1 | my $c = 0; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 293 | 1 | my @keep; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 294 | 1 | ▶ | for my $m ( @{ $pf->{queue} || [] } ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition50%1/2
$$pf{'queue'} || []
MC/DC0%0/1
$$pf{'queue'} || []
$$pf{'queue'}
Truth table50%1/2
A
A= $$pf{'queue'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 295 | 1 | ▶ | my $hit = ( $all || $want{ $m->{id} } ) && ( !$act{queue} || ( $m->{queue} // 'deferred' ) eq $act{queue} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition27%3/11
($all || $want{$$m{'id'}}) && (!$act{'queue'} || ($$m{'queue'} // 'deferred') eq $act{'queue'})
$all or $want{$$m{"id"}}
not $act{"queue"} or ($$m{"queue"} // "deferred") eq $act{"queue"}
$$m{"queue"} // "deferred"
MC/DC0%0/4
($all || $want{$$m{'id'}}) && (!$act{'queue'} || ($$m{'queue'} // 'deferred') eq $act{'queue'})
$all
$want{$$m{"id"}}
not $act{"queue"}
$$m{"queue"}
Truth table14%1/7
A or B && not(C) or D
A= $allB= $want{$$m{"id"}}C= not $act{"queue"}D= $$m{"queue"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 296 | 0 | ▶ | if ( !$hit ) { push @keep, $m; next } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 297 | 1 | $c++; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 298 | 1 | ▶ | if ( $op eq 'd' ) { push @{ $pf->{deleted} }, $m->{id}; next } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 3 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 299 | 0 | elsif ( $op eq 'h' ) { $m->{queue} = 'hold' } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 300 | 0 | ▶ | elsif ( $op eq 'H' ) { $m->{queue} = 'deferred' if ( $m->{queue} // '' ) eq 'hold' } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/2
$$m{"queue"} // ""
MC/DC0%0/1
$$m{"queue"} // ""
$$m{"queue"}
Truth table0%0/2
A
A= $$m{"queue"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 301 | 0 | push @keep, $m; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 302 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 303 | 1 | $pf->{queue} = \@keep; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 304 | 1 | my %verb = ( d => 'Deleted', h => 'Placed on hold', H => 'Released from hold', r => 'Requeued' ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 305 | 1 | ▶ | push @l, "postsuper: $verb{$op}: $c message" . ( $c == 1 ? '' : 's' ) if $c; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 306 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 307 | 1 | return ( join( "\n", @l ), 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 308 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 309 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 310 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 311 | 0 | ▶ | sub postcat { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
postcat: not called CC=6 SCAR=37.4
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 312 | 0 | my ( $dev, $av ) = @_; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 313 | 0 | my ($id) = grep { !/\A-/ } @$av; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 314 | 0 | ▶ | my ($m) = grep { $_->{id} eq ( $id // '' ) } @{ $dev->{postfix}{queue} || [] }; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition0%0/4
$id // ""
$$dev{'postfix'}{'queue'} || []
MC/DC0%0/1
$id // ""
$id
MC/DC0%0/1
$$dev{'postfix'}{'queue'} || []
$$dev{'postfix'}{'queue'}
Truth table0%0/2
A
A= $id
Truth table0%0/2
A
A= $$dev{'postfix'}{'queue'}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 315 | 0 | ▶ | return ( "postcat: fatal: open queue file $id: No such file or directory", 0 ) unless $m; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 316 | return ( join( "\n", '*** ENVELOPE RECORDS deferred/' . $m->{id} . ' ***', "message_size: $m->{size}", "sender: $m->{from}", | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 317 | 0 | ▶ | ( map {"recipient: $_"} @{ $m->{to} || [] } ), '*** MESSAGE CONTENTS deferred/' . $m->{id} . ' ***', ( $m->{headers} // '' ) =~ s/\n\z//r, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Condition0%0/4
$$m{'to'} || []
$$m{"headers"} // ""
MC/DC0%0/1
$$m{'to'} || []
$$m{'to'}
MC/DC0%0/1
$$m{"headers"} // ""
$$m{"headers"}
Truth table0%0/2
A
A= $$m{'to'}
Truth table0%0/2
A
A= $$m{"headers"}
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 318 | 0 | '*** HEADER EXTRACTED deferred/' . $m->{id} . ' ***', '*** MESSAGE FILE END deferred/' . $m->{id} . ' ***' ), 1 ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 319 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 320 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 321 | 2 | 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 322 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 323 | __END__ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||