From 31746e3c6bd42c9bea4a2a1986c35a1fa8118f7c Mon Sep 17 00:00:00 2001 From: "Fabio M. Di Nitto" Date: Thu, 10 Aug 2017 15:47:41 +0200 Subject: [PATCH] [compress zlib] fix log levels around Signed-off-by: Fabio M. Di Nitto --- libknet/compress_zlib.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/libknet/compress_zlib.c b/libknet/compress_zlib.c index 0256e08..fbf4b3b 100644 --- a/libknet/compress_zlib.c +++ b/libknet/compress_zlib.c @@ -59,22 +59,22 @@ int zlib_compress( savederrno = 0; break; case Z_MEM_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress mem error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress mem error"); err = -1; savederrno = ENOMEM; break; case Z_BUF_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress buf error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress buf error"); err = -1; savederrno = ENOBUFS; break; case Z_STREAM_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress stream error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress stream error"); err = -1; savederrno = EINVAL; break; default: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib compress unknown error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib unknown compress error: %d", zerr); break; } @@ -104,22 +104,22 @@ int zlib_decompress( savederrno = 0; break; case Z_MEM_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress mem error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress mem error"); err = -1; savederrno = ENOMEM; break; case Z_BUF_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress buf error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress buf error"); err = -1; savederrno = ENOBUFS; break; case Z_DATA_ERROR: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress data error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib decompress data error"); err = -1; savederrno = EINVAL; break; default: - log_debug(knet_h, KNET_SUB_ZLIBCOMP, "zlib unknown error"); + log_err(knet_h, KNET_SUB_ZLIBCOMP, "zlib unknown decompress error: %d", zerr); break; } -- 2.39.5