From 1fd2695e0267b2537d748f55e30f6e6cb16f4e68 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Mon, 29 May 2017 09:13:19 +0200 Subject: [PATCH] Fix compiler warnings refs #5287 --- lib/perfdata/graphitewriter.cpp | 2 -- lib/remote/jsonrpcconnection.cpp | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/perfdata/graphitewriter.cpp b/lib/perfdata/graphitewriter.cpp index df493d7d2..febc8dfbb 100644 --- a/lib/perfdata/graphitewriter.cpp +++ b/lib/perfdata/graphitewriter.cpp @@ -136,8 +136,6 @@ void GraphiteWriter::Reconnect(void) SetShouldConnect(true); - bool reconnect = false; - if (GetConnected()) return; diff --git a/lib/remote/jsonrpcconnection.cpp b/lib/remote/jsonrpcconnection.cpp index ef8ef0d89..5ad7fd0ad 100644 --- a/lib/remote/jsonrpcconnection.cpp +++ b/lib/remote/jsonrpcconnection.cpp @@ -347,9 +347,9 @@ int JsonRpcConnection::GetWorkQueueCount(void) int JsonRpcConnection::GetWorkQueueLength(void) { - size_t itemCount = 0; + int itemCount = 0; - for (size_t i = 0; i < GetWorkQueueCount(); i++) { + for (int i = 0; i < GetWorkQueueCount(); i++) { itemCount += l_JsonRpcConnectionWorkQueues[i].GetLength(); } @@ -365,7 +365,7 @@ double JsonRpcConnection::GetWorkQueueRate(void) if (count == 0) return 0.0; - for (size_t i = 0; i < count; i++) { + for (int i = 0; i < count; i++) { rate += l_JsonRpcConnectionWorkQueues[i].GetTaskCount(60) / 60.0; } -- 2.40.0