From: Vsevolod Stakhov Date: Fri, 12 Aug 2016 10:20:28 +0000 (+0100) Subject: [Fix] Fix returning of REDIS_NIL X-Git-Tag: 1.3.3~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca2374d88c09759f2a46e68801e5eb557eee7d3b;p=thirdparty%2Frspamd.git [Fix] Fix returning of REDIS_NIL --- diff --git a/src/lua/lua_redis.c b/src/lua/lua_redis.c index c35d9614bb..1fc8e17774 100644 --- a/src/lua/lua_redis.c +++ b/src/lua/lua_redis.c @@ -271,8 +271,7 @@ lua_redis_push_reply (lua_State *L, const redisReply *r) lua_pushnumber (L, r->integer); break; case REDIS_REPLY_NIL: - /* XXX: not the best approach */ - lua_newuserdata (L, sizeof (gpointer)); + lua_pushnil (L); break; case REDIS_REPLY_STRING: case REDIS_REPLY_STATUS: