]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_alias.cpp
Add new cross-module event system
[user/henk/code/inspircd.git] / src / modules / m_alias.cpp
index 2d4bdded30fa70515972fb827bd0034ba1a41440..5b3979179bc0d39e665ea710693cbea277bc1a60 100644 (file)
@@ -63,7 +63,7 @@ class ModuleAlias : public Module
         * We can, however, use a fancy invention: the multimap. Maps a key to one or more values.
         *              -- w00t
      */
-       typedef std::multimap<std::string, Alias, irc::insensitive_swo> AliasMap;
+       typedef insp::flat_multimap<std::string, Alias, irc::insensitive_swo> AliasMap;
 
        AliasMap Aliases;
 
@@ -148,7 +148,7 @@ class ModuleAlias : public Module
                        return MOD_RES_PASSTHRU;
 
                /* The parameters for the command in their original form, with the command stripped off */
-               std::string compare = original_line.substr(command.length());
+               std::string compare(original_line, command.length());
                while (*(compare.c_str()) == ' ')
                        compare.erase(compare.begin());
 
@@ -212,7 +212,7 @@ class ModuleAlias : public Module
                        return;
 
                /* The parameters for the command in their original form, with the command stripped off */
-               std::string compare = text.substr(scommand.length() + 1);
+               std::string compare(text, scommand.length() + 1);
                while (*(compare.c_str()) == ' ')
                        compare.erase(compare.begin());