mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2024-12-23 03:40:05 +00:00
Fix newline characters being stripped from emails
This commit is contained in:
parent
c8ff130b78
commit
156e9bf902
@ -767,7 +767,7 @@ void BuddyManager::emailSend(CNSocket* sock, CNPacketData* data) {
|
||||
U16toU8(plr->PCStyle.szFirstName), // SenderFirstName
|
||||
U16toU8(plr->PCStyle.szLastName), // SenderLastName
|
||||
ChatManager::sanitizeText(U16toU8(pkt->szSubject)), // SubjectLine
|
||||
ChatManager::sanitizeText(U16toU8(pkt->szContent)), // MsgBody
|
||||
ChatManager::sanitizeText(U16toU8(pkt->szContent), true), // MsgBody
|
||||
pkt->iCash, // Taros
|
||||
(uint64_t)getTimestamp(), // SendTime
|
||||
0 // DeleteTime (unimplemented)
|
||||
|
@ -936,7 +936,7 @@ std::string ChatManager::sanitizeText(std::string text, bool allowNewlines) {
|
||||
if (!allowNewlines && c == '\n')
|
||||
continue;
|
||||
|
||||
if (c >= ' ' && c <= '~')
|
||||
if (c >= ' ' && c <= '~' || c == '\n')
|
||||
buf[i++] = c;
|
||||
}
|
||||
buf[i] = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user