]> jfr.im git - irc/quakenet/newserv.git/blobdiff - lua/lua.h
LUA: Add servername and servernumeric nickpushers.
[irc/quakenet/newserv.git] / lua / lua.h
index ac33db310097c3252d6347b8b0581a3ccdd321e3..3eec9e4a9baad560bb73a816fb4a026e4db3303a 100644 (file)
--- a/lua/lua.h
+++ b/lua/lua.h
@@ -5,7 +5,9 @@
 #ifndef _LUA_H
 #define _LUA_H
 
+#ifndef __USE_BSD
 #define __USE_BSD
+#endif
 
 #include <lua.h>
 #include <lauxlib.h>
@@ -21,6 +23,7 @@
 
 #include "lualocal.h"
 #include "luasocket.h"
+#include "luascheduler.h"
 
 #define luamalloc(x) nsmalloc(POOL_LUA, x)
 #define luarealloc(x, y) nsrealloc(POOL_LUA, x, y)
@@ -28,8 +31,8 @@
 
 /*** defines ************************************/
 
-#define LUA_BOTVERSION "1.87"
-#define LUA_CHANFIXBOT "D"
+#define LUA_BOTVERSION "1.94"
+#define LUA_CHANFIXBOT "N2"
 #define LUA_OPERCHAN "#twilightzone"
 
 #ifndef LUA_PUKECHAN
@@ -48,7 +51,8 @@
 #define LUA_AUXVERSION ""
 #endif
 
-#define LUA_FULLVERSION "Lua engine v" LUA_BOTVERSION " (" LUA_VERSION LUA_AUXVERSION ")"
+#define LUA_SMALLVERSION "v" LUA_BOTVERSION " (" LUA_VERSION LUA_AUXVERSION ")"
+#define LUA_FULLVERSION "Lua engine " LUA_SMALLVERSION
 
 /*** end defines ************************************/
 
@@ -61,13 +65,14 @@ typedef struct lua_list {
   struct lua_list *prev;
   lua_localnick *nicks;
   lua_socket *sockets;
+  lua_scheduler *schedulers;
 } lua_list;
 
 #define LUA_STARTLOOP(l) { lua_list *ll; for(ll=lua_head;ll;ll=ll->next) {  l = ll->l
 
 #define LUA_ENDLOOP() } }
 
-#define LUA_PATHLEN 1024
+#define LUA_PATHLEN 150
 
 extern lua_list *lua_head;
 extern sstring *cpath;
@@ -110,27 +115,11 @@ extern struct rusage r_usagee;
 
 #ifdef LUA_DEBUGSOCKET
 
-void lua_debugoutput(char *p, ...);
+void lua_debugoutput(char *p, ...) __attribute__ ((format (printf, 1, 2)));
 #define DEBUGOUT(p, ...) lua_debugoutput(p , ##__VA_ARGS__)
 
 #endif
 
-#ifndef INLINE
-
-#ifdef __GNUC__
-#define INLINE __attribute((always_inline)) inline
-#endif
-
-#ifdef _MSC_VER
-#define INLINE __forceinline
-#endif
-
-#ifndef INLINE
-#define INLINE inline
-#endif
-
-#endif /* INLINE */
-
-INLINE int lua_debugpcall(lua_State *l, char *message, int a, int b, int c);
+int lua_debugpcall(lua_State *l, char *message, int a, int b, int c);
 
 #endif