diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/command_parse.h | 30 | ||||
-rw-r--r-- | include/commands.h | 2 | ||||
-rw-r--r-- | include/dns.h | 7 | ||||
-rw-r--r-- | include/inspircd.h | 6 |
4 files changed, 38 insertions, 7 deletions
diff --git a/include/command_parse.h b/include/command_parse.h new file mode 100644 index 000000000..098c8330f --- /dev/null +++ b/include/command_parse.h @@ -0,0 +1,30 @@ +/* +------------------------------------+ + * | Inspire Internet Relay Chat Daemon | + * +------------------------------------+ + * + * Inspire is copyright (C) 2002-2005 ChatSpike-Dev. + * E-mail: + * <brain@chatspike.net> + * <Craig@chatspike.net> + * + * Written by Craig Edwards, Craig McLure, and others. + * This program is free but copyrighted software; see + * the file COPYING for details. + * + * --------------------------------------------------- + */ + +#ifndef __COMMAND_PARSE_H +#define __COMMAND_PARSE_H + +#include <typeinfo> +#include <iostream> +#include <string> +#include "users.h" + +void call_handler(std::string &commandname,char **parameters, int pcnt, userrec *user); +bool is_valid_cmd(std::string &commandname, int pcnt, userrec * user); +int loop_call(handlerfunc fn, char **parameters, int pcnt, userrec *u, int start, int end, int joins); +void process_buffer(const char* cmdbuf,userrec *user); + +#endif diff --git a/include/commands.h b/include/commands.h index f05e9dac0..115705eb5 100644 --- a/include/commands.h +++ b/include/commands.h @@ -2,7 +2,7 @@ * | Inspire Internet Relay Chat Daemon | * +------------------------------------+ * - * Inspire is copyright (C) 2002-2004 ChatSpike-Dev. + * Inspire is copyright (C) 2002-2005 ChatSpike-Dev. * E-mail: * <brain@chatspike.net> * <Craig@chatspike.net> diff --git a/include/dns.h b/include/dns.h index 63d5bb1fb..33b5f8c7a 100644 --- a/include/dns.h +++ b/include/dns.h @@ -97,4 +97,11 @@ public: void SetNS(std::string dnsserver); }; +/** This is the handler function for multi-threaded DNS. + * It cannot be a class member as pthread will not let us + * create a thread whos handler function is a member of + * a class (ugh). + */ +void* dns_task(void* arg); + #endif diff --git a/include/inspircd.h b/include/inspircd.h index ad95d859e..0ebc3420c 100644 --- a/include/inspircd.h +++ b/include/inspircd.h @@ -114,14 +114,8 @@ class InspIRCd }; -/* prototypes */ -void call_handler(std::string &commandname,char **parameters, int pcnt, userrec *user); -bool is_valid_cmd(std::string &commandname, int pcnt, userrec * user); -int loop_call(handlerfunc fn, char **parameters, int pcnt, userrec *u, int start, int end, int joins); /* userrec optimization stuff */ void AddServerName(std::string servername); const char* FindServerNamePtr(std::string servername); -void* dns_task(void* arg); -void process_buffer(const char* cmdbuf,userrec *user); #endif |