From 746ced2308f606ddaa2781ada5eac4e4364b8f3f Mon Sep 17 00:00:00 2001 From: Aaron Jones Date: Tue, 11 Jun 2024 17:53:36 +0000 Subject: [PATCH] Revert "Fix WHOIS reply not respecting a lack of the multi-prefix capability" A server handling a remote WHOIS cannot safely use IsCapable() to determine if the client has multi-prefix enabled or not. This is because client capabilities are not shared between servers; and the IsCapable() macro dereferences source_p->localClient which will be NULL if source_p is not on this server. Instead rework the commit to always pretend that multi-prefix is not enabled, to still respect the fact that multiple prefixes should not be returned in case a client does not have multi-prefix enabled. This reverts commit 4633665ad62bdfe26529 --- modules/m_whois.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/m_whois.c b/modules/m_whois.c index ea94e1db..c4e82ad0 100644 --- a/modules/m_whois.c +++ b/modules/m_whois.c @@ -279,7 +279,7 @@ single_whois(struct Client *source_p, struct Client *target_p, int operspy) { send_multiline_item(source_p, "%s%s%s", hdata_vis.approved ? "" : "!", - find_channel_status(mt, IsCapable(source_p, CLICAP_MULTI_PREFIX)), + find_channel_status(mt, 0), chptr->chname); } }