/[smecontribs]/rpms/smeserver-vacation/contribs9/smeserver-vacation-1.1-bz6614-autodetect.html.patch
ViewVC logotype

Annotation of /rpms/smeserver-vacation/contribs9/smeserver-vacation-1.1-bz6614-autodetect.html.patch

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


Revision 1.1 - (hide annotations) (download)
Mon Jan 16 21:50:15 2017 UTC (7 years, 10 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-vacation-1_1-24_el6_sme
* Mon Jan 16 2017 Jean-Philipe Pialasse <tests@pialasse.com> 1.1-24.sme
- NFR allow html message and auto detect to switch from text to html [SME: 6614]

1 unnilennium 1.1 diff -Nur smeserver-vacation-1.1.old/root/usr/local/bin/vacation smeserver-vacation-1.1/root/usr/local/bin/vacation
2     --- smeserver-vacation-1.1.old/root/usr/local/bin/vacation 2017-01-16 16:44:03.999000000 -0500
3     +++ smeserver-vacation-1.1/root/usr/local/bin/vacation 2017-01-16 16:48:09.939000000 -0500
4     @@ -493,6 +493,8 @@
5     exit(0) if ($no_msg_no_reply);
6     }
7    
8     + my $type = ($vacation_msg =~ m/^<html/ && $vacation_msg =~ m/<\/html>/ ) ? 'html':'plain';
9     +
10     $vacation_msg =~ s/\$SUBJECT/$subject/g;
11    
12     open(MAILPROG, "| $mailprog");
13     @@ -500,7 +502,7 @@
14     print MAILPROG << "EOF";
15     To: $sender
16     Precedence: junk
17     -Content-Type: text/plain; charset="UTF-8"
18     +Content-Type: text/$type; charset="UTF-8"
19     EOF
20    
21     print MAILPROG $vacation_msg;

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