aboutsummaryrefslogtreecommitdiff
path: root/src/modules/m_cap.cpp
diff options
context:
space:
mode:
authorGravatar Attila Molnar2014-02-06 23:00:18 +0100
committerGravatar Attila Molnar2014-02-06 23:00:18 +0100
commit13edc2e8eb1404e51131468451ed64ef4d25cdaf (patch)
tree10141b160bd22f34dc12e9917876b6053c4c6ec2 /src/modules/m_cap.cpp
parentMerge pull request #766 from SaberUK/master+rebuild-fix (diff)
m_cap Instead of using case insensitive compare convert the subcommand to uppercase
This way if we send back the subcommand it will be in uppercase even if the client sent it in lowercase
Diffstat (limited to 'src/modules/m_cap.cpp')
-rw-r--r--src/modules/m_cap.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/m_cap.cpp b/src/modules/m_cap.cpp
index 605423ae0..968c304ab 100644
--- a/src/modules/m_cap.cpp
+++ b/src/modules/m_cap.cpp
@@ -49,7 +49,8 @@ class CommandCAP : public Command
CmdResult Handle (const std::vector<std::string> &parameters, User *user)
{
- irc::string subcommand = parameters[0].c_str();
+ std::string subcommand(parameters[0].length(), ' ');
+ std::transform(parameters[0].begin(), parameters[0].end(), subcommand.begin(), ::toupper);
if (subcommand == "REQ")
{