summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2024-03-15 18:51:17 (GMT)
committerSadie Powell <sadie@witchery.services>2024-03-15 18:52:12 (GMT)
commitd41764bfd6b22417ac5ff4993c4f8961e20f58c6 (patch)
tree4ee2b3115f3151d4b2758e1d2423b21954f5b986
parent10f4724b6babe7fc313801924d50a5ec854e7134 (diff)
downloadanope-2.0.zip
anope-2.0.tar.gz
anope-2.0.tar.bz2
Fix sending emails to nicks ending with a backslash.HEAD2.0
-rw-r--r--src/mail.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mail.cpp b/src/mail.cpp
index 68f51c5..03b1be3 100644
--- a/src/mail.cpp
+++ b/src/mail.cpp
@@ -48,7 +48,7 @@ void Mail::Message::Run()
if (this->dont_quote_addresses)
fprintf(pipe, "To: %s <%s>\r\n", mail_to.c_str(), addr.c_str());
else
- fprintf(pipe, "To: \"%s\" <%s>\r\n", mail_to.c_str(), addr.c_str());
+ fprintf(pipe, "To: \"%s\" <%s>\r\n", mail_to.replace_all_cs("\\", "\\\\").c_str(), addr.c_str());
fprintf(pipe, "Subject: %s\r\n", subject.c_str());
fprintf(pipe, "Content-Type: %s\r\n", content_type.c_str());
fprintf(pipe, "Content-Transfer-Encoding: 8bit\r\n");