lua: add uloop support
authorFelix Fietkau <nbd@openwrt.org>
Thu, 27 Sep 2012 11:59:47 +0000 (13:59 +0200)
committerFelix Fietkau <nbd@openwrt.org>
Thu, 27 Sep 2012 11:59:47 +0000 (13:59 +0200)
lua/ubus.c

index c9c1108e75ab37e09211d4ca6e5afbe082363949..29ba1ae34b6468922ca185ce800d8b12edbc2a60 100644 (file)
@@ -226,6 +226,7 @@ ubus_lua_connect(lua_State *L)
        if ((c = lua_newuserdata(L, sizeof(*c))) != NULL &&
                (c->ctx = ubus_connect(sockpath)) != NULL)
        {
+               ubus_add_uloop(c->ctx);
                c->timeout = timeout;
                memset(&c->buf, 0, sizeof(c->buf));
                luaL_getmetatable(L, METANAME);