mirror of
https://github.com/znc/znc.git
synced 2026-07-06 01:41:12 +02:00
send 422 event if MOTD buffer is empty
This commit is contained in:
+8
-3
@@ -403,9 +403,14 @@ void CIRCNetwork::ClientConnected(CClient *pClient) {
|
||||
|
||||
// Send the cached MOTD
|
||||
uSize = m_MotdBuffer.Size();
|
||||
for (uIdx = 0; uIdx < uSize; uIdx++) {
|
||||
pClient->PutClient(m_MotdBuffer.GetLine(uIdx, *pClient, msParams));
|
||||
}
|
||||
if (uSize > 0) {
|
||||
for (uIdx = 0; uIdx < uSize; uIdx++) {
|
||||
pClient->PutClient(m_MotdBuffer.GetLine(uIdx, *pClient, msParams));
|
||||
}
|
||||
}
|
||||
else {
|
||||
pClient->PutClient(":irc.znc.in 422 :MOTD File is missing");
|
||||
}
|
||||
|
||||
if (GetIRCSock() != NULL) {
|
||||
CString sUserMode("");
|
||||
|
||||
Reference in New Issue
Block a user