diff options
author | ShooterIT <wangyuancode@163.com> | 2020-05-21 21:00:21 +0800 |
---|---|---|
committer | ShooterIT <wangyuancode@163.com> | 2020-05-21 21:00:30 +0800 |
commit | 9018ddc32a2246fe806eba96bf13bb461c8000fc (patch) | |
tree | 063c607d6b21dcd1f9f949ff34693f2eb2b17428 | |
parent | af34245692214d778268d2c3afd795255530a7ec (diff) | |
download | redis-9018ddc32a2246fe806eba96bf13bb461c8000fc.tar.gz |
Fix reply bytes calculation error
Fix #7275.
-rw-r--r-- | src/networking.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/networking.c b/src/networking.c index 0a04c0489..e6c48ac77 100644 --- a/src/networking.c +++ b/src/networking.c @@ -488,7 +488,7 @@ void trimReplyUnusedTailSpace(client *c) { /* take over the allocation's internal fragmentation (at least for * memory usage tracking) */ tail->size = zmalloc_usable(tail) - sizeof(clientReplyBlock); - c->reply_bytes += tail->size - old_size; + c->reply_bytes = c->reply_bytes + tail->size - old_size; listNodeValue(ln) = tail; } } |