diff --git a/Client.cpp b/Client.cpp index 09afc5c8..e63d8643 100644 --- a/Client.cpp +++ b/Client.cpp @@ -284,7 +284,10 @@ void CClient::ReadLine(const CString& sData) { if (m_pUser->IsChan(sTarget)) { CChan *pChan = m_pUser->FindChan(sTarget); - if (pChan && sModes.empty() && !pChan->GetModeString().empty()) { + // If we are on that channel and already received a + // /mode reply from the server, we can answer this + // request ourself. + if (pChan && pChan->IsOn() && sModes.empty() && !pChan->GetModeString().empty()) { PutClient(":" + m_pUser->GetIRCServer() + " 324 " + GetNick() + " " + sTarget + " " + pChan->GetModeString()); if (pChan->GetCreationDate() > 0) { PutClient(":" + m_pUser->GetIRCServer() + " 329 " + GetNick() + " " + sTarget + " " + CString(pChan->GetCreationDate()));