]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/hashcomp.cpp
Add <options:cyclehosts> which allows a user to appear to have quit when their host...
[user/henk/code/inspircd.git] / src / hashcomp.cpp
index 953997e5b83c9dd2b8549fd2500fd4026c4e88e5..f5cc5efe05c71e3e154ba31eb8897af60c7d4e19 100644 (file)
@@ -20,13 +20,11 @@ using namespace std;
 #include "inspircd.h"
 #include <string>
 #include "hashcomp.h"
-#include "helperfuncs.h"
+
 #include <ext/hash_map>
 
 #define nspace __gnu_cxx
 
-char lowermap[255];
-
 /******************************************************
  *
  * The hash functions of InspIRCd are the centrepoint
@@ -127,9 +125,7 @@ bool irc::InAddr_HashComp::operator()(const insp_inaddr &s1, const insp_inaddr &
  * std::string which is not only case-insensitive but
  * can also do scandanavian comparisons, e.g. { = [, etc.
  *
- * This class depends on the global 'lowermap' which is
- * initialized at startup by inspircd.cpp, and contains
- * the 'scandanavian' casemappings for fast irc compare.
+ * This class depends on the const array 'lowermap'.
  *
  ******************************************************/
 
@@ -282,18 +278,3 @@ const std::string irc::commasepstream::GetToken()
 irc::commasepstream::~commasepstream()
 {
 }
-
-void InspIRCd::MakeLowerMap()
-{       
-       // initialize the lowercase mapping table
-       for (unsigned char cn = 0; cn < 255; cn++)
-               lowermap[cn] = cn;
-       // lowercase the uppercase chars
-       for (unsigned char cn = 65; cn < 91; cn++)
-               lowermap[cn] = tolower(cn);
-       // now replace the specific chars for scandanavian comparison
-       lowermap[(unsigned char)'['] = '{';
-       lowermap[(unsigned char)']'] = '}';
-       lowermap[(unsigned char)'\\'] = '|';
-}
-