Added error reporting and quit msgs as *status output

git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@729 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
prozacx
2006-05-02 01:16:38 +00:00
parent cf663f8f63
commit cd0e37c9ad
+13
View File
@@ -64,6 +64,15 @@ void CIRCSock::ReadLine(const CString& sData) {
if (strncasecmp(sLine.c_str(), "PING ", 5) == 0) {
PutIRC("PONG " + sLine.substr(5));
} else if (strncasecmp(sLine.c_str(), "ERROR ", 6) == 0) {
//ERROR :Closing Link: nick[24.24.24.24] (Excess Flood)
CString sError(sLine.substr(7));
if (sError.Left(1) == ":") {
sError.LeftChomp();
}
m_pUser->PutStatus("Error from Server [" + sError + "]");
} else if (sLine.WildCmp(":* * *")) { //"^:(\\S+) (\\d\\d\\d) (.*?) (.*)$", vCap)) {
CString sCmd = sLine.Token(1);
@@ -400,6 +409,10 @@ void CIRCSock::ReadLine(const CString& sData) {
// :nick!ident@host.com QUIT :message
if (Nick.GetNick().CaseCmp(GetNick()) == 0) {
m_pUser->PutStatus("You quit [" + sMessage + "]");
}
vector<CChan*> vFoundChans;
const vector<CChan*>& vChans = m_pUser->GetChans();