From fca537cc21702e88e04fb084b08e2e3958cbc374 Mon Sep 17 00:00:00 2001
From: "Mirar (Pontus Hagland)" <pike@sort.mirar.org>
Date: Tue, 3 Oct 2000 10:25:13 +0200
Subject: [PATCH] added (cautious) \n -> \r\n converter for simple mail (it's
 suposed to be simple)

Rev: lib/modules/Protocols.pmod/SMTP.pmod:1.14
---
 lib/modules/Protocols.pmod/SMTP.pmod | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/modules/Protocols.pmod/SMTP.pmod b/lib/modules/Protocols.pmod/SMTP.pmod
index c1c675cc28..f1788e4e76 100644
--- a/lib/modules/Protocols.pmod/SMTP.pmod
+++ b/lib/modules/Protocols.pmod/SMTP.pmod
@@ -102,6 +102,8 @@ class client
 
   void simple_mail(string to, string subject, string from, string msg)
   {
+    if (search(msg,"\r\n")==-1)
+      msg=replace(msg,"\n","\r\n"); // *simple* mail /Mirar
     send_message(parse_addr(from), ({ parse_addr(to) }),
 		 (string)MIME.Message(msg, (["mime-version":"1.0",
 					     "subject":subject,
-- 
GitLab