Commit 7ea870c0 authored by antirez's avatar antirez
Browse files

Use writev(2) if glue output buffers is disabled

parent 89ee361e
...@@ -1385,14 +1385,13 @@ static void sendReplyToClient(aeEventLoop *el, int fd, void *privdata, int mask) ...@@ -1385,14 +1385,13 @@ static void sendReplyToClient(aeEventLoop *el, int fd, void *privdata, int mask)
/* Use writev() if we have enough buffers to send */ /* Use writev() if we have enough buffers to send */
#if 0 if (!server.glueoutputbuf &&
if (listLength(c->reply) > REDIS_WRITEV_THRESHOLD && listLength(c->reply) > REDIS_WRITEV_THRESHOLD &&
!(c->flags & REDIS_MASTER)) !(c->flags & REDIS_MASTER))
{ {
sendReplyToClientWritev(el, fd, privdata, mask); sendReplyToClientWritev(el, fd, privdata, mask);
return; return;
} }
#endif
while(listLength(c->reply)) { while(listLength(c->reply)) {
if (server.glueoutputbuf && listLength(c->reply) > 1) if (server.glueoutputbuf && listLength(c->reply) > 1)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment