diff options
author | Sadie Powell <sadie@witchery.services> | 2025-04-10 13:06:37 +0100 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2025-04-15 19:30:59 +0100 |
commit | a883b616a1360ba74254661cbd39280404d1753a (patch) | |
tree | b58c7913ea6a2c3a78b4edb79cd64b465e101b99 /src/bots.cpp | |
parent | b421ba258e4332d512edab35ddc3e6e41e297381 (diff) |
Automatically line wrap messages sent by services.
Diffstat (limited to 'src/bots.cpp')
-rw-r--r-- | src/bots.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/bots.cpp b/src/bots.cpp index d2cbd0cb4..33afc7595 100644 --- a/src/bots.cpp +++ b/src/bots.cpp @@ -299,7 +299,10 @@ Anope::string BotInfo::GetQueryCommand(const Anope::string &command, const Anope if (!extra.empty()) buf.append(" ").append(extra); - return buf; + // We use a substitute (ASCII 0x1A) instead of a space (ASCII 0x20) so it + // doesn't get line wrapped when put into a message. The line wrapper will + // convert this to a space before it is sent to clients. + return buf.replace_all_cs("\x20", "\x1A"); } BotInfo *BotInfo::Find(const Anope::string &nick, bool nick_only) |