X-Git-Url: http://git.pk910.de/?a=blobdiff_plain;f=src%2Fmodules%2Fmodule.h;h=4c55c40ef650cbc802e17dad1b183ee6b2f1c3af;hb=d29f5ec1df18f814aaaa96dcd86ed40b17821bb0;hp=5e203a76e506e60f937bc43811d73634b0331173;hpb=c49eed20311de32444533a519fa6fbacab481688;p=NeonServV5.git diff --git a/src/modules/module.h b/src/modules/module.h index 5e203a7..4c55c40 100644 --- a/src/modules/module.h +++ b/src/modules/module.h @@ -1,4 +1,4 @@ -/* module.h - NeonServ v5.5 +/* module.h - NeonServ v5.6 * Copyright (C) 2011-2012 Philipp Kreil (pk910) * * This program is free software: you can redistribute it and/or modify @@ -20,6 +20,7 @@ #include "../overall.h" #include "../version.h" #include "../mysqlConn.h" +#include "../log.h" extern void **global; extern int module_id; @@ -27,15 +28,17 @@ extern int module_id; /**** global function list ****/ /* 000 */ #define getStartTime ((time_t (*)(void))global[0]) /* 001 */ #define getRunningThreads ((int (*)(void))global[1]) -/* 002 */ #define exit_daemon ((int (*)(void))global[2]) +/* 002 */ #define getCurrentSecondsOfDay ((int (*)(void))global[2]) /* 003 */ #define stricmp ((int (*)(const char *, const char *))global[3]) /* 004 */ #define stricmplen ((int (*)(const char *, const char *, int))global[4]) -/* 005 */ #define restart_process ((void (*)(void))global[5]) -/* 006 */ #define cleanup ((void (*)(void))global[6]) +#ifdef ENABLE_MUTEX_DEBUG +/* 005 */ #define xmutex ((void (*)(int, pthread_mutex_t *, const char *, unsigned int))global[005]) +/* 006 */ #define mutex_debug ((void (*)(pthread_mutex_t *))global[006]) +#endif /* 007 */ #define restart_bot ((void (*)(int))global[7]) /* 008 */ #define stop_bot ((void (*)(void))global[8]) /* 009 */ #define reload_config ((void (*)(void))global[9]) -/* 010 */ #define putlog ((void (*)(int, const char *, ...))global[10]) +/* 010 */ #define printf_log ((void (*)(char *, int, const char *, ...))global[10]) #ifdef HAVE_THREADS /* 011 */ #define getCurrentThreadID ((int (*)(void))global[11]) #endif @@ -84,8 +87,8 @@ extern int module_id; /* 054 */ #define unbind_nick ((void (*)(nick_func_t *))global[54]) /* 055 */ #define bind_part ((int (*)(part_func_t *, int))global[55]) /* 056 */ #define unbind_part ((void (*)(part_func_t *))global[56]) -/* 057 */ /* deprecated */ -/* 058 */ /* deprecated */ +/* 057 */ #define bind_reload ((int (*)(reload_func_t *, int))global[57]) +/* 058 */ #define unbind_reload ((void (*)(reload_func_t *))global[58]) /* 059 */ #define bind_kick ((int (*)(kick_func_t *, int))global[59]) /* 060 */ #define unbind_kick ((void (*)(kick_func_t *))global[60]) /* 061 */ #define bind_topic ((int (*)(topic_func_t *, int))global[61]) @@ -224,6 +227,10 @@ extern int module_id; /* 192 */ #define module_global_cmd_unregister_neonbackup ((void (*)(char *))global[192]) /* 193 */ #define module_neonbackup_recover_chan ((void (*)(struct ChanNode *))global[193]) /* 194 */ #define requestInvite ((void (*)(struct UserNode *, struct ChanNode *))global[194]) +/* 195 */ #define is_stable_revision ((const int (*)(void))global[195]) +/* 196 */ #define get_dev_revision ((const char * (*)(void))global[196]) +/* 197 */ #define bind_freeclient ((int (*)(freeclient_func_t *, int))global[197]) +/* 198 */ #define unbind_freeclient ((void (*)(freeclient_func_t *))global[198]) #define MODULE_HEADER(initfunc,startfunc,stopfunc) \ void **global = NULL; \