Skip to content

Commit

Permalink
[Minor] Fix khash set operation
Browse files Browse the repository at this point in the history
  • Loading branch information
vstakhov committed Sep 16, 2019
1 parent 66fb742 commit 2cdad98
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lua/lua_common.c
Expand Up @@ -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 */
Expand Down

0 comments on commit 2cdad98

Please sign in to comment.