/[smecontribs]/rpms/smeserver-vacation/contribs10/smeserver-vacation-1.1-multiline_matching.patch
ViewVC logotype

Contents of /rpms/smeserver-vacation/contribs10/smeserver-vacation-1.1-multiline_matching.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Tue Apr 14 14:42:40 2020 UTC (4 years, 7 months ago) by brianr
Branch: MAIN
CVS Tags: smeserver-vacation-1_1-34_el7_sme, smeserver-vacation-1_1-31_el7_sme, smeserver-vacation-1_1-32_el7_sme, smeserver-vacation-1_1-30_el7_sme, smeserver-vacation-1_1-35_el7_sme, smeserver-vacation-1_1-36_el7_sme, smeserver-vacation-1_1-26_el7_sme, smeserver-vacation-1_1-27_el7_sme, smeserver-vacation-1_1-33_el7_sme, smeserver-vacation-1_1-28_el7_sme, smeserver-vacation-1_1-29_el7_sme, HEAD
Initial import

1 diff -Nur smeserver-vacation-1.1/root/usr/local/bin/vacation smeserver-vacation-1.1_bz8742/root/usr/local/bin/vacation
2 --- smeserver-vacation-1.1/root/usr/local/bin/vacation 2014-12-24 10:04:10.100000000 +0100
3 +++ smeserver-vacation-1.1_bz8742/root/usr/local/bin/vacation 2014-12-24 10:06:32.588000000 +0100
4 @@ -413,30 +413,28 @@
5 $header = <STDIN>;
6 $header =~ s/\n\s+/ /g; # Join continuation lines
7
8 - $* = 1; # Multi line matching within a string
9 -
10 - exit(0) if ($header =~ /^Precedence:\s+(bulk|junk|list)/i);
11 - exit(0) if ($header =~ /^From.*-REQUEST\@/i);
12 - exit(0) if ($header =~ /^Mailing-List:/i);
13 - exit(0) if ($header =~ /^X-Spam-Status:\s+Yes/i);
14 + exit(0) if ($header =~ /^Precedence:\s+(bulk|junk|list)/im);
15 + exit(0) if ($header =~ /^From.*-REQUEST\@/im);
16 + exit(0) if ($header =~ /^Mailing-List:/im);
17 + exit(0) if ($header =~ /^X-Spam-Status:\s+Yes/im);
18
19 if ($check_to_and_cc)
20 {
21 - ($to) = ($header =~ /To:\s+(.*)/i);
22 - ($cc) = ($header =~ /Cc:\s+(.*)/i);
23 + ($to) = ($header =~ /To:\s+(.*)/im);
24 + ($cc) = ($header =~ /Cc:\s+(.*)/im);
25 $to .= ', ' . $cc if $cc;
26 $to = lc($to);
27
28 for (@aliases)
29 {
30 - ++$alias_match if $to =~ /\b$_\b/;
31 + ++$alias_match if $to =~ /\b$_\b/im;
32 }
33
34 exit(0) unless $alias_match;
35 }
36
37 - ($subject) = ($header =~ /^Subject:\s+(.*)/);
38 - $subject =~ s/\s*$//; # Remove trailing spaces
39 + ($subject) = ($header =~ /^Subject:\s+(.*)/m);
40 + $subject =~ s/\s*$//m; # Remove trailing spaces
41
42 $subject = "(No subject)" unless $subject;
43 }

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed