From 5332021086065874fb8080999eb797fb6c46ceb5 Mon Sep 17 00:00:00 2001 From: rickone Date: Fri, 1 Apr 2016 12:39:09 +0800 Subject: [PATCH] Update redis.lua MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit exec执行时其中一条出错,看不到错误信息 --- lualib/redis.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lualib/redis.lua b/lualib/redis.lua index 3fc14a58..09147817 100644 --- a/lualib/redis.lua +++ b/lualib/redis.lua @@ -54,11 +54,10 @@ redcmd[42] = function(fd, data) -- '*' local noerr = true for i = 1,n do local ok, v = read_response(fd) - if ok then - bulk[i] = v - else + if not ok then noerr = false end + bulk[i] = v end return noerr, bulk end