summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/scripting.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/scripting.c b/src/scripting.c
index 8eddb2a5e..a71622e51 100644
--- a/src/scripting.c
+++ b/src/scripting.c
@@ -312,6 +312,7 @@ int luaRedisGenericCommand(lua_State *lua, int raise_error) {
* the client buffer directly. */
c->buf[c->bufpos] = '\0';
reply = c->buf;
+ c->bufpos = 0;
} else {
reply = sdsnewlen(c->buf,c->bufpos);
c->bufpos = 0;