summaryrefslogtreecommitdiff
path: root/src/l_log.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/l_log.c')
-rw-r--r--src/l_log.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/l_log.c b/src/l_log.c
index ea9d1a3..7fb4e79 100644
--- a/src/l_log.c
+++ b/src/l_log.c
@@ -1,15 +1,15 @@
/*
* gcsd
*
- * gcsd the generic command sequencer daemon can be used to serialize
+ * gcsd the generic command sequencer daemon can be used to serialize
* commands sent over various paralell communication channels to a
* single command output. It can be seen as a multiplexer for any
* kind of communication between a single resource and various clients
* which want to submit commands to it or query information from it.
- * gcsd is written in C and Lua. The goal is to provide an easy to
+ * gcsd is written in C and Lua. The goal is to provide an easy to
* understand high level API based on Lua which can be used to
* implement the business logic of the so formed multiplexer daemon.
- *
+ *
*
* Copyright (C) 2009-2010 Markus Grueneis <gimpf@spreadspace.org>
* Christian Pointner <equinox@spreadspace.org>
@@ -64,7 +64,7 @@ static int l_log_add_target(lua_State *L)
default: lua_pushstring(L, "syntax error"); break;
}
return 2;
- }
+ }
lua_pushboolean(L, 1);
return 1;
@@ -84,22 +84,22 @@ static int l_log_printf(lua_State *L)
lua_remove(L, -1);
lua_call(L, numargs - 1, 1);
}
-
+
log_prio_t prio = luaL_checkint(L,1);
log_printf(prio, "%s", luaL_checkstring(L, 2));
return 0;
}
static const struct luaL_reg log_funcs [] = {
- { "init", l_log_init },
- { "close", l_log_close },
+ { "init", l_log_init },
+ { "close", l_log_close },
{ "add_target", l_log_add_target },
{ "printf", l_log_printf },
{ NULL, NULL }
};
-LUALIB_API int luaopen_log(lua_State *L)
+LUALIB_API int luaopen_log(lua_State *L)
{
luaL_register(L, LUA_LOGLIBNAME, log_funcs);
lua_pushliteral(L, "ERROR");