From 6e5713d64a379fc64c7ff6658362d02b3618c3ca Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Mon, 24 Jun 2024 13:29:41 +0100 Subject: Remove the formatting overloads of SendNotice/SendPrivmsg. --- modules/botserv/botserv.cpp | 3 ++- modules/botserv/bs_control.cpp | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'modules/botserv') diff --git a/modules/botserv/botserv.cpp b/modules/botserv/botserv.cpp index 706865522..c9172ba0e 100644 --- a/modules/botserv/botserv.cpp +++ b/modules/botserv/botserv.cpp @@ -75,7 +75,8 @@ public: { ChannelMode *cm = ModeManager::FindChannelModeByName("OP"); char symbol = cm ? anope_dynamic_static_cast(cm)->symbol : 0; - IRCD->SendNotice(bi, (symbol ? Anope::string(symbol) : "") + c->name, "%s invited %s into the channel.", user->nick.c_str(), user->nick.c_str()); + const auto message = Anope::printf("%s invited %s into the channel.", user->nick.c_str(), user->nick.c_str()); + IRCD->SendNotice(bi, (symbol ? Anope::string(symbol) : "") + c->name, message); } ModeManager::ProcessModes(); diff --git a/modules/botserv/bs_control.cpp b/modules/botserv/bs_control.cpp index 32101be6e..1784914b6 100644 --- a/modules/botserv/bs_control.cpp +++ b/modules/botserv/bs_control.cpp @@ -56,7 +56,7 @@ public: return; } - IRCD->SendPrivmsg(*ci->bi, ci->name, "%s", text.c_str()); + IRCD->SendPrivmsg(*ci->bi, ci->name, text); ci->bi->lastmsg = Anope::CurTime; bool override = !source.AccessFor(ci).HasPriv("SAY"); -- cgit