modified code to use IOHandler functions instead of own ones
[NeonServV5.git] / src / modules / module.h
index 50207b5a8e0d29d5553f5f7a8c9eff86939f7dd8..5e203a76e506e60f937bc43811d73634b0331173 100644 (file)
@@ -58,9 +58,9 @@ extern int module_id;
 /* 028 */ #define getChannelUsers ((struct ChanUser* (*)(struct ChanNode *, struct ChanUser *))global[28])
 /* 029 */ #define getUserChannels ((struct ChanUser* (*)(struct UserNode *, struct ChanUser *))global[29])
 /* 030 */ #define create_socket ((struct ClientSocket* (*)(char *, int, char *, char *, char *, char *, char *))global[30])
-/* 031 */ #define connect_socket ((int (*)(struct ClientSocket *))global[31])
+/* 031 */ #define connect_socket ((void (*)(struct ClientSocket *))global[31])
 /* 032 */ #define close_socket ((int (*)(struct ClientSocket *))global[32])
-/* 033 */ #define disconnect_socket ((int (*)(struct ClientSocket *))global[33])
+/* 033 */ #define destroy_socket ((int (*)(struct ClientSocket *))global[33])
 /* 034 */ #define write_socket ((int (*)(struct ClientSocket *, char*, int))global[34])
 /* 035 */ #define putsock ((void (*)(struct ClientSocket *, const char *, ...))global[35])
 /* 036 */ #define getBots ((struct ClientSocket* (*)(int, struct ClientSocket *))global[36])
@@ -225,7 +225,7 @@ extern int module_id;
 /* 193 */ #define module_neonbackup_recover_chan ((void (*)(struct ChanNode *))global[193])
 /* 194 */ #define requestInvite ((void (*)(struct UserNode *, struct ChanNode *))global[194])
 
-#define MODULE_HEADER(initfunc,startfunc,loopfunc,stopfunc) \
+#define MODULE_HEADER(initfunc,startfunc,stopfunc) \
     void **global = NULL; \
     int module_id = 0; \
     int init_module(void **functions, int modid) { \
@@ -236,9 +236,6 @@ extern int module_id;
     void start_module(int type) { \
         startfunc(type); \
     } \
-    void loop_module() { \
-        loopfunc(); \
-    } \
     void stop_module(int type) { \
         stopfunc(type); \
     } \