Merge AddService(), AddClone() into AddLocalUser()
[srvx.git] / src / proto.h
index 9f0f77a18f7b26539a4dea5be49012913ca9a5f1..451c889f365dbc4dafb774731b48b4fb80b169ab 100644 (file)
@@ -1,5 +1,5 @@
 /* proto.h - IRC protocol output
- * Copyright 2000-2004 srvx Development Team
+ * Copyright 2000-2006 srvx Development Team
  *
  * This file is part of srvx.
  *
@@ -94,12 +94,12 @@ void init_parse(void);
 int parse_line(char *line, int recursive);
 
 /* Callback notifications for protocol support. */
-typedef void (*chanmsg_func_t) (struct userNode *user, struct chanNode *chan, char *text, struct userNode *bot);
+typedef void (*chanmsg_func_t) (struct userNode *user, struct chanNode *chan, const char *text, struct userNode *bot);
 void reg_chanmsg_func(unsigned char prefix, struct userNode *service, chanmsg_func_t handler);
 void reg_allchanmsg_func(struct userNode *service, chanmsg_func_t handler);
 struct userNode *get_chanmsg_bot(unsigned char prefix);
 
-typedef void (*privmsg_func_t) (struct userNode *user, struct userNode *target, char *text, int server_qualified);
+typedef void (*privmsg_func_t) (struct userNode *user, struct userNode *target, const char *text, int server_qualified);
 void reg_privmsg_func(struct userNode *user, privmsg_func_t handler);
 void reg_notice_func(struct userNode *user, privmsg_func_t handler);
 void unreg_privmsg_func(struct userNode *user, privmsg_func_t handler);
@@ -167,8 +167,7 @@ void irc_numeric(struct userNode *user, unsigned int num, const char *format, ..
 /* stuff originally from other headers that is really protocol-specific */
 int IsChannelName(const char *name);
 int is_valid_nick(const char *nick);
-struct userNode *AddService(const char *nick, const char *modes, const char *desc, const char *hostname);
-struct userNode *AddClone(const char *nick, const char *ident, const char *hostname, const char *desc);
+struct userNode *AddLocalUser(const char *nick, const char *ident, const char *hostname, const char *desc, const char *modes);
 struct server* AddServer(struct server* uplink, const char *name, int hops, time_t boot, time_t link, const char *numeric, const char *description);
 void DelServer(struct server* serv, int announce, const char *message);
 void DelUser(struct userNode* user, struct userNode *killer, int announce, const char *why);
@@ -218,7 +217,7 @@ struct mod_chanmode {
 
 struct mod_chanmode *mod_chanmode_alloc(unsigned int argc);
 struct mod_chanmode *mod_chanmode_dup(struct mod_chanmode *orig, unsigned int extra);
-struct mod_chanmode *mod_chanmode_parse(struct chanNode *channel, char **modes, unsigned int argc, unsigned int flags);
+struct mod_chanmode *mod_chanmode_parse(struct chanNode *channel, char **modes, unsigned int argc, unsigned int flags, short base_oplevel);
 void mod_chanmode_apply(struct userNode *who, struct chanNode *channel, struct mod_chanmode *change);
 void mod_chanmode_announce(struct userNode *who, struct chanNode *channel, struct mod_chanmode *change);
 char *mod_chanmode_format(struct mod_chanmode *desc, char *buffer);