]> jfr.im git - irc/quakenet/newserv.git/blobdiff - lua/luadb.c
CHANSERV: better batcher error handling for expired accounts/accounts with no email.
[irc/quakenet/newserv.git] / lua / luadb.c
index 3c2fba129a4a0da1a072ec9f930c8b3f88c6bdaa..d0c6e4031b12b425ef992c0aa82002eaa6f79249 100644 (file)
@@ -14,7 +14,7 @@ static int lua_dbcreatequery(lua_State *ps) {
   if(!s)
     LUA_RETURN(ps, LUA_FAIL);
 
-  dbcreatequery(s);
+  dbcreatequery("%s", s);
   LUA_RETURN(ps, LUA_OK);
 }
 
@@ -94,7 +94,7 @@ static int lua_dbquery(lua_State *ps) {
     LUA_RETURN(ps, LUA_FAIL);
 
   if(!lua_isfunction(ps, 2)) {
-    dbquery(q);
+    dbquery("%s", q);
     LUA_RETURN(ps, LUA_OK);
   }
 
@@ -106,7 +106,7 @@ static int lua_dbquery(lua_State *ps) {
   cb->args = luaL_ref(ps, LUA_REGISTRYINDEX);
   cb->handler = luaL_ref(ps, LUA_REGISTRYINDEX);
 
-  dbasyncquery(lua_dbcallback, cb, q);
+  dbasyncquery(lua_dbcallback, cb, "%s", q);
 
   LUA_RETURN(ps, LUA_OK);
 }