diff options
author | Sadie Powell <sadie@witchery.services> | 2024-03-15 18:51:17 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-03-15 18:52:12 +0000 |
commit | d41764bfd6b22417ac5ff4993c4f8961e20f58c6 (patch) | |
tree | 4ee2b3115f3151d4b2758e1d2423b21954f5b986 /src/mail.cpp | |
parent | 10f4724b6babe7fc313801924d50a5ec854e7134 (diff) |
Fix sending emails to nicks ending with a backslash.
Diffstat (limited to 'src/mail.cpp')
-rw-r--r-- | src/mail.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mail.cpp b/src/mail.cpp index 68f51c556..03b1be318 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"); |