From d655946faa44d84536f12718e1947c5f9737211a Mon Sep 17 00:00:00 2001 From: Uwe Klotz Date: Thu, 31 Dec 2020 14:06:07 +0100 Subject: WebTask: Simplify the consistency check --- src/network/webtask.cpp | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) (limited to 'src/network') diff --git a/src/network/webtask.cpp b/src/network/webtask.cpp index d626f64d17..72f3b06c87 100644 --- a/src/network/webtask.cpp +++ b/src/network/webtask.cpp @@ -309,20 +309,13 @@ void WebTask::slotNetworkReplyFinished() { // Check correlation between pending and finished reply auto* const pPendingNetworkReply = m_pendingNetworkReplyWeakPtr.data(); - if (!pPendingNetworkReply) { - // No reply is pending - DEBUG_ASSERT(m_state == State::Aborted || m_state == State::TimedOut); - DEBUG_ASSERT(m_timeoutTimerId == kInvalidTimerId); - kLogger.debug() - << this - << "Discarding obsolete network reply"; - return; - } VERIFY_OR_DEBUG_ASSERT(pPendingNetworkReply == pFinishedNetworkReply) { - // Another reply is pending - kLogger.debug() + // Another or no reply is pending + kLogger.warning() << this - << "Discarding unexpected network reply"; + << "Discarding unexpected network reply:" + << "finished =" << pFinishedNetworkReply + << "pending =" << pPendingNetworkReply; return; } -- cgit v1.2.3