diff options
author | Sadie Powell <sadie@witchery.services> | 2024-06-24 14:29:55 +0100 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-06-24 14:29:55 +0100 |
commit | 693eeed762eac490b1289f8f4428ff0b5bbf1672 (patch) | |
tree | 974cbad287da04fc9e137d7f51092efd2e474acd /src/protocol.cpp | |
parent | 6e5713d64a379fc64c7ff6658362d02b3618c3ca (diff) |
Rework how CTCP messages are sent and received.
Diffstat (limited to 'src/protocol.cpp')
-rw-r--r-- | src/protocol.cpp | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/protocol.cpp b/src/protocol.cpp index 275721634..1c5edd2a4 100644 --- a/src/protocol.cpp +++ b/src/protocol.cpp @@ -166,12 +166,6 @@ void IRCDProto::SendGlobops(const MessageSource &source, const Anope::string &me Uplink::Send(source, "GLOBOPS", message); } -void IRCDProto::SendCTCPInternal(const MessageSource &source, const Anope::string &dest, const Anope::string &buf) -{ - Anope::string s = Anope::NormalizeBuffer(buf); - this->SendNotice(source, dest, "\1" + s + "\1"); -} - void IRCDProto::SendNumericInternal(int numeric, const Anope::string &dest, const std::vector<Anope::string> ¶ms) { Anope::string n = Anope::ToString(numeric); @@ -190,17 +184,6 @@ void IRCDProto::SendTopic(const MessageSource &source, Channel *c) Uplink::Send(source, "TOPIC", c->name, c->topic); } -void IRCDProto::SendAction(const MessageSource &source, const Anope::string &dest, const char *fmt, ...) -{ - va_list args; - char buf[BUFSIZE] = ""; - va_start(args, fmt); - vsnprintf(buf, BUFSIZE - 1, fmt, args); - va_end(args); - Anope::string actionbuf = Anope::string("\1ACTION ") + buf + '\1'; - SendPrivmsg(source, dest, actionbuf); -} - void IRCDProto::SendPing(const Anope::string &servname, const Anope::string &who) { if (servname.empty()) @@ -243,16 +226,6 @@ void IRCDProto::SendForceNickChange(User *u, const Anope::string &newnick, time_ Uplink::Send("SVSNICK", u->GetUID(), newnick, when); } -void IRCDProto::SendCTCP(const MessageSource &source, const Anope::string &dest, const char *fmt, ...) -{ - va_list args; - char buf[BUFSIZE] = ""; - va_start(args, fmt); - vsnprintf(buf, BUFSIZE - 1, fmt, args); - va_end(args); - SendCTCPInternal(source, dest, buf); -} - bool IRCDProto::IsNickValid(const Anope::string &nick) { /** |