]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/hashcomp.cpp
Add Ankit to regular contributors list
[user/henk/code/inspircd.git] / src / hashcomp.cpp
index a613a8073eab57502847d10326a65e883a8aa8c5..ab4d8368ddbb42a0f3351d4408d4d37132c4b08a 100644 (file)
@@ -2,11 +2,11 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
  * See: http://www.inspircd.org/wiki/index.php/Credits
  *
  * This program is free but copyrighted software; see
- *            the file COPYING for details.
+ *         the file COPYING for details.
  *
  * ---------------------------------------------------
  */
@@ -501,3 +501,25 @@ long irc::portparser::GetToken()
        }
 }
 
+/*const std::basic_string& SearchAndReplace(std::string& text, const std::string& pattern, const std::string& replace)
+{
+       std::string replacement;
+       if ((!pattern.empty()) && (!text.empty()))
+       {
+               for (std::string::size_type n = 0; n != text.length(); ++n)
+               {
+                       if (text.length() >= pattern.length() && text.substr(n, pattern.length()) == pattern)
+                       {
+                               replacement.append(replace);
+                               n = n + pattern.length() - 1;
+                       }
+                       else
+                       {
+                               replacement += text[n];
+                       }
+               }
+       }
+       text = replacement;
+       return text;
+}*/
+