| 1242 |
*/ |
*/ |
| 1243 |
static int lua_ap_scoreboard_worker(lua_State *L) |
static int lua_ap_scoreboard_worker(lua_State *L) |
| 1244 |
{ |
{ |
| 1245 |
int i, |
int i, j; |
| 1246 |
j; |
worker_score *ws_record = NULL; |
| 1247 |
worker_score *ws_record; |
request_rec *r = NULL; |
| 1248 |
|
|
| 1249 |
luaL_checktype(L, 1, LUA_TUSERDATA); |
luaL_checktype(L, 1, LUA_TUSERDATA); |
| 1250 |
luaL_checktype(L, 2, LUA_TNUMBER); |
luaL_checktype(L, 2, LUA_TNUMBER); |
| 1251 |
luaL_checktype(L, 3, LUA_TNUMBER); |
luaL_checktype(L, 3, LUA_TNUMBER); |
| 1252 |
|
|
| 1253 |
|
r = ap_lua_check_request_rec(L, 1); |
| 1254 |
|
if (!r) return 0; |
| 1255 |
|
|
| 1256 |
i = lua_tointeger(L, 2); |
i = lua_tointeger(L, 2); |
| 1257 |
j = lua_tointeger(L, 3); |
j = lua_tointeger(L, 3); |
| 1258 |
ws_record = ap_get_scoreboard_worker_from_indexes(i, j); |
ws_record = apr_palloc(r->pool, sizeof *ws_record); |
| 1259 |
|
|
| 1260 |
|
ap_copy_scoreboard_worker(ws_record, i, j); |
| 1261 |
if (ws_record) { |
if (ws_record) { |
| 1262 |
lua_newtable(L); |
lua_newtable(L); |
| 1263 |
|
|