Some weird clients might send a nickmask prefix, handle this correctly

*cough* eggdrop is evil *cough*

Thanks to dare for debugging this.


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1144 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2008-07-23 13:36:04 +00:00
parent abeba8aea7
commit cd8318370a

View File

@@ -46,6 +46,12 @@ void CClient::ReadLine(const CString& sData) {
#endif
CString sCommand = sLine.Token(0);
if (sCommand.Left(1) == ":") {
// Evil client! Sending a nickmask prefix on client's command
// is bad, bad, bad, bad, bad, bad, bad, bad, BAD, B A D!
sLine = sLine.Token(1, true);
sCommand = sLine.Token(0);
}
if (sCommand.CaseCmp("PASS") == 0) {
if (!IsAttached()) {