From f9dcc2617602627fbf3888372d888ef6523a7b04 Mon Sep 17 00:00:00 2001 From: "Ruben S. Montero" Date: Fri, 8 Jan 2021 14:06:07 +0100 Subject: [PATCH] B #5219: High CPU consumption by onemonitord --- src/common/NebulaUtil.cc | 2 +- src/monitor/src/protocol/Message.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/NebulaUtil.cc b/src/common/NebulaUtil.cc index 9086fc85cd..1150647a25 100644 --- a/src/common/NebulaUtil.cc +++ b/src/common/NebulaUtil.cc @@ -641,7 +641,7 @@ string * one_util::zlib_decompress(const string& in, bool base64) rc = inflate(&zs, Z_FINISH); - if ( rc != Z_STREAM_END && rc != Z_OK && rc != Z_BUF_ERROR ) + if ( rc != Z_STREAM_END && rc != Z_OK ) { inflateEnd(&zs); diff --git a/src/monitor/src/protocol/Message.cc b/src/monitor/src/protocol/Message.cc index 3c85f43f92..e953a680fa 100644 --- a/src/monitor/src/protocol/Message.cc +++ b/src/monitor/src/protocol/Message.cc @@ -173,7 +173,7 @@ int zlib_decompress(const std::string& in, std::string& out) rc = inflate(&zs, Z_FINISH); - if ( rc != Z_STREAM_END && rc != Z_OK && rc != Z_BUF_ERROR ) + if ( rc != Z_STREAM_END && rc != Z_OK ) { inflateEnd(&zs);