mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 00:28:26 -05:00
RESP3: Lua double -> RESP3 conversion.
This commit is contained in:
parent
89f929b12a
commit
8ea4bdd91d
@ -389,6 +389,17 @@ void luaReplyToRedisReply(client *c, lua_State *lua) {
|
||||
}
|
||||
lua_pop(lua,1); /* Discard field name pushed before. */
|
||||
|
||||
/* Handle double reply. */
|
||||
lua_pushstring(lua,"double");
|
||||
lua_gettable(lua,-2);
|
||||
t = lua_type(lua,-1);
|
||||
if (t == LUA_TNUMBER) {
|
||||
addReplyDouble(c,lua_tonumber(lua,-1));
|
||||
lua_pop(lua,2);
|
||||
return;
|
||||
}
|
||||
lua_pop(lua,1); /* Discard field name pushed before. */
|
||||
|
||||
/* Handle map reply. */
|
||||
lua_pushstring(lua,"map");
|
||||
lua_gettable(lua,-2);
|
||||
|
Loading…
Reference in New Issue
Block a user