X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fuci.git;a=blobdiff_plain;f=lua%2Fuci.c;fp=lua%2Fuci.c;h=1cb31a594c7823144dd5200c7656b38c4ea4d65b;hp=6ba7da07f9e8793f2b1e54ddda6ff60c120a55fe;hb=aaf9dff96d391f1d3fdc73dc5eb14b0d6b51085d;hpb=2cd94fd505b293e657278e31deb32a7d66d20714 diff --git a/lua/uci.c b/lua/uci.c index 6ba7da0..1cb31a5 100644 --- a/lua/uci.c +++ b/lua/uci.c @@ -303,7 +303,7 @@ uci_lua_foreach(lua_State *L) ctx = find_context(L, &offset); package = luaL_checkstring(L, 1 + offset); - if (lua_isnil(L, 2)) + if (lua_isnil(L, 2 + offset)) type = NULL; else type = luaL_checkstring(L, 2 + offset);