From 73dbbddd8af8ae260f68308e408a94f292cc1d71 Mon Sep 17 00:00:00 2001 From: Wiebe Cazemier Date: Mon, 24 May 2021 13:43:14 +0200 Subject: [PATCH] Debug log line for QoS queue --- session.cpp | 4 ++++ 1 file changed, 4 insertions(+), 0 deletions(-) diff --git a/session.cpp b/session.cpp index a4a06fa..51f922b 100644 --- a/session.cpp +++ b/session.cpp @@ -96,6 +96,10 @@ void Session::writePacket(const MqttPacket &packet, char max_qos) // should be acked in order. void Session::clearQosMessage(uint16_t packet_id) { +#ifndef NDEBUG + logger->logf(LOG_DEBUG, "Clearing QoS message for '%s', packet id '%d'. Left in queue: %d", client_id.c_str(), packet_id, qosPacketQueue.size()); +#endif + std::lock_guard locker(qosQueueMutex); auto it = qosPacketQueue.begin(); -- libgit2 0.21.4