From fcd65a5842015906ed2f16d0d01826a93dfd70a6 Mon Sep 17 00:00:00 2001 From: lganzzzo Date: Wed, 3 Oct 2018 21:06:22 +0300 Subject: [PATCH] Better error message, and proper log level for StreamBufferProxy flushAsync --- core/data/stream/StreamBufferedProxy.cpp | 2 +- web/server/HttpProcessor.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/core/data/stream/StreamBufferedProxy.cpp b/core/data/stream/StreamBufferedProxy.cpp index fb9b1436..aeeb4ce6 100644 --- a/core/data/stream/StreamBufferedProxy.cpp +++ b/core/data/stream/StreamBufferedProxy.cpp @@ -130,7 +130,7 @@ oatpp::async::Action OutputStreamBufferedProxy::flushAsync(oatpp::async::Abstrac } else if(result > 0){ m_stream->m_pos += (v_bufferSize) result; } - return error("OutputStreamBufferedProxy. Failed to flush all data"); + return error("[oatpp::data::stream::OutputStreamBufferedProxy::flushAsync()]: Error - Failed to flush all data"); } return finish(); diff --git a/web/server/HttpProcessor.cpp b/web/server/HttpProcessor.cpp index 59fbea5f..90c32e03 100644 --- a/web/server/HttpProcessor.cpp +++ b/web/server/HttpProcessor.cpp @@ -198,9 +198,9 @@ HttpProcessor::Coroutine::Action HttpProcessor::Coroutine::onRequestDone() { HttpProcessor::Coroutine::Action HttpProcessor::Coroutine::handleError(const oatpp::async::Error& error) { if(m_currentResponse) { if(error.isExceptionThrown) { - OATPP_LOGD("Server", "Unhandled exception. Dropping connection"); + OATPP_LOGE("Server", "Unhandled exception. Dropping connection"); } else { - OATPP_LOGD("Server", "Unhandled error. '%s'. Dropping connection", error.message); + OATPP_LOGE("Server", "Unhandled error. '%s'. Dropping connection", error.message); } return abort(); }