From: Vsevolod Stakhov Date: Mon, 16 Sep 2019 12:37:51 +0000 (+0100) Subject: [Minor] Fix khash set operation X-Git-Tag: 2.0~203 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=2cdad98690ea42c0b0322f3de913adfb24332277;p=rspamd.git [Minor] Fix khash set operation --- diff --git a/src/lua/lua_common.c b/src/lua/lua_common.c index 562adf5d5..bfd572532 100644 --- a/src/lua/lua_common.c +++ b/src/lua/lua_common.c @@ -1248,7 +1248,7 @@ rspamd_lua_check_class (lua_State *L, gint index, const gchar *name) } lua_rawgetp (L, LUA_REGISTRYINDEX, - RSPAMD_LIGHTUSERDATA_MASK (kh_value (lua_classes, k))); + RSPAMD_LIGHTUSERDATA_MASK (kh_key (lua_classes, k))); if (lua_rawequal (L, -1, -2)) { /* does it have the correct mt? */ lua_pop (L, 2); /* remove both metatables */