aboutsummaryrefslogtreecommitdiffstats
path: root/src/signal.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/signal.c')
-rw-r--r--src/signal.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/signal.c b/src/signal.c
index 232a4b7..c833315 100644
--- a/src/signal.c
+++ b/src/signal.c
@@ -7,6 +7,7 @@
#include <unistd.h>
#define REG_TABLE "luasignal"
+#define VERSION "LuaSignal 0.1"
static lua_State* gL = NULL;
static lua_Hook old_hook = NULL;
@@ -322,6 +323,8 @@ int luaopen_signal(lua_State* L)
lua_setfield(L, LUA_REGISTRYINDEX, REG_TABLE);
luaL_register(L, "signal", reg);
+ lua_pushstring(L, VERSION);
+ lua_setfield(L, -2, "_VERSION");
return 1;
}