summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-15 22:10:12 +0000
committerw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-15 22:10:12 +0000
commit0fb5041fc842ef0e65dc14c6ab6415e018b129b5 (patch)
treefb44d67b97d981ff7542cc509c5f7fadc233e548 /src
parent2c25d4a34428088b9407be14740041346500eb5f (diff)
Move some other stuff to helperfuncs (uline related, and timestring)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8213 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/command_parse.cpp23
-rw-r--r--src/helperfuncs.cpp22
2 files changed, 22 insertions, 23 deletions
diff --git a/src/command_parse.cpp b/src/command_parse.cpp
index 9a525dd5b..3b87112a9 100644
--- a/src/command_parse.cpp
+++ b/src/command_parse.cpp
@@ -25,24 +25,6 @@
#include <dlfcn.h>
#endif
-bool InspIRCd::ULine(const char* server)
-{
- if (!server)
- return false;
- if (!*server)
- return true;
-
- return (Config->ulines.find(server) != Config->ulines.end());
-}
-
-bool InspIRCd::SilentULine(const char* server)
-{
- std::map<irc::string,bool>::iterator n = Config->ulines.find(server);
- if (n != Config->ulines.end())
- return n->second;
- else return false;
-}
-
int InspIRCd::OperPassCompare(const char* data,const char* input, int tagnumber)
{
int MOD_RESULT = 0;
@@ -54,11 +36,6 @@ int InspIRCd::OperPassCompare(const char* data,const char* input, int tagnumber)
return strcmp(data,input);
}
-std::string InspIRCd::TimeString(time_t curtime)
-{
- return std::string(ctime(&curtime),24);
-}
-
/* LoopCall is used to call a command classes handler repeatedly based on the contents of a comma seperated list.
* There are two overriden versions of this method, one of which takes two potential lists and the other takes one.
* We need a version which takes two potential lists for JOIN, because a JOIN may contain two lists of items at once,
diff --git a/src/helperfuncs.cpp b/src/helperfuncs.cpp
index 63f599f75..ceb4711a9 100644
--- a/src/helperfuncs.cpp
+++ b/src/helperfuncs.cpp
@@ -592,4 +592,26 @@ long InspIRCd::Duration(const std::string &str)
return total + subtotal;
}
+bool InspIRCd::ULine(const char* server)
+{
+ if (!server)
+ return false;
+ if (!*server)
+ return true;
+
+ return (Config->ulines.find(server) != Config->ulines.end());
+}
+
+bool InspIRCd::SilentULine(const char* server)
+{
+ std::map<irc::string,bool>::iterator n = Config->ulines.find(server);
+ if (n != Config->ulines.end())
+ return n->second;
+ else return false;
+}
+
+std::string InspIRCd::TimeString(time_t curtime)
+{
+ return std::string(ctime(&curtime),24);
+}