Skip to content

Commit

Permalink
Show 410 to client for unknown CAP subcommand.
Browse files Browse the repository at this point in the history
It's in CAP specs.
  • Loading branch information
DarthGandalf committed Jul 24, 2012
1 parent 9e4733d commit 07cb02c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Client.cpp
Expand Up @@ -798,6 +798,7 @@ void CClient::RespondCap(const CString& sResponse)

void CClient::HandleCap(const CString& sLine)
{
//TODO support ~ and = modifiers
CString sSubCmd = sLine.Token(1);

if (sSubCmd.Equals("LS")) {
Expand Down Expand Up @@ -896,5 +897,7 @@ void CClient::HandleCap(const CString& sLine)
sList += "-" + *i + " ";
}
RespondCap("ACK :" + sList.TrimSuffix_n(" "));
} else {
PutClient(":irc.znc.in 410 " + GetNick() + " :Invalid CAP subcommand");
}
}

0 comments on commit 07cb02c

Please sign in to comment.