Skip to content
Snippets Groups Projects
Commit c8e0c28c authored by Jo-Philipp Wich's avatar Jo-Philipp Wich
Browse files

iwinfo: make 'type' visible in wrapped iwinfo


There are several cases within 'luci' that attempt to access the interface
'type' from within the 'type' specific meta tables; however, 'type' is not
currently available there.  Replicate the common metadata in the 'type'
specific meta tables.

Signed-off-by: default avatarNathan Hintz <nlhintz@hotmail.com>

SVN-Revision: 38448
parent 494bc1d0
No related branches found
No related tags found
No related merge requests found
......@@ -7,7 +7,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libiwinfo
PKG_RELEASE:=46
PKG_RELEASE:=47
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
PKG_CONFIG_DEPENDS := \
......
......@@ -862,6 +862,7 @@ LUALIB_API int luaopen_iwinfo(lua_State *L) {
#ifdef USE_WL
luaL_newmetatable(L, IWINFO_WL_META);
luaL_register(L, NULL, R_common);
luaL_register(L, NULL, R_wl);
lua_pushvalue(L, -1);
lua_setfield(L, -2, "__index");
......@@ -870,6 +871,7 @@ LUALIB_API int luaopen_iwinfo(lua_State *L) {
#ifdef USE_MADWIFI
luaL_newmetatable(L, IWINFO_MADWIFI_META);
luaL_register(L, NULL, R_common);
luaL_register(L, NULL, R_madwifi);
lua_pushvalue(L, -1);
lua_setfield(L, -2, "__index");
......@@ -878,6 +880,7 @@ LUALIB_API int luaopen_iwinfo(lua_State *L) {
#ifdef USE_NL80211
luaL_newmetatable(L, IWINFO_NL80211_META);
luaL_register(L, NULL, R_common);
luaL_register(L, NULL, R_nl80211);
lua_pushvalue(L, -1);
lua_setfield(L, -2, "__index");
......@@ -885,6 +888,7 @@ LUALIB_API int luaopen_iwinfo(lua_State *L) {
#endif
luaL_newmetatable(L, IWINFO_WEXT_META);
luaL_register(L, NULL, R_common);
luaL_register(L, NULL, R_wext);
lua_pushvalue(L, -1);
lua_setfield(L, -2, "__index");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment