From e93523c42e373cfc7bf070526582b1bb5e2ad89c Mon Sep 17 00:00:00 2001 From: psychon Date: Thu, 21 Oct 2010 17:27:19 +0000 Subject: [PATCH] partyline: Only inject prefixes if we know the prefixes There are apparently "IRC" daemons (which don't deserve that name) that don't send any 005. Yes, I'm looking at you, chat.wikileaks.org. For these servers we shouldn't inject partyline's channel prefix because that makes us send out a "CHANTYPES=~" line which severely confuses clients. XChat then turns everything into a query! git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@2162 726aef4b-f618-498e-8847-2d620e286838 --- modules/partyline.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/partyline.cpp b/modules/partyline.cpp index 998154be..e7829a7c 100644 --- a/modules/partyline.cpp +++ b/modules/partyline.cpp @@ -184,7 +184,7 @@ public: } virtual void OnClientLogin() { - if (m_spInjectedPrefixes.find(m_pUser) == m_spInjectedPrefixes.end()) { + if (m_spInjectedPrefixes.find(m_pUser) == m_spInjectedPrefixes.end() && !m_pUser->GetChanPrefixes().empty()) { m_pClient->PutClient(":" + GetIRCServer(m_pUser) + " 005 " + m_pUser->GetIRCNick().GetNick() + " CHANTYPES=" + m_pUser->GetChanPrefixes() + CHAN_PREFIX_1 " :are supported by this server."); }