summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSalvatore Sanfilippo <antirez@gmail.com>2015-05-04 12:19:44 +0200
committerSalvatore Sanfilippo <antirez@gmail.com>2015-05-04 12:19:44 +0200
commit22d00d80cee85219a2c6e489592b4d8b86c16bd4 (patch)
treea0630eb2598c9f6a2cec5de6217fbda3f42d272e /src
parent827d07f005c8fcdfa839d9541e7f2c2a9d4aa0fd (diff)
parent49c1b60bd8cbca6bbec7a171645dfeb67c1a7ddf (diff)
downloadredis-22d00d80cee85219a2c6e489592b4d8b86c16bd4.tar.gz
Merge pull request #2542 from yossigo/lua_client_buffer_crash
Fix Redis server crash when Lua command exceeds client output buffer limit.
Diffstat (limited to 'src')
-rw-r--r--src/networking.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/networking.c b/src/networking.c
index 761645cb2..19032ae01 100644
--- a/src/networking.c
+++ b/src/networking.c
@@ -805,7 +805,7 @@ void freeClient(redisClient *c) {
* a context where calling freeClient() is not possible, because the client
* should be valid for the continuation of the flow of the program. */
void freeClientAsync(redisClient *c) {
- if (c->flags & REDIS_CLOSE_ASAP) return;
+ if (c->flags & REDIS_CLOSE_ASAP || c->flags & REDIS_LUA_CLIENT) return;
c->flags |= REDIS_CLOSE_ASAP;
listAddNodeTail(server.clients_to_close,c);
}