From 0c4e94cff06031b15a144744667ccf453157d68b Mon Sep 17 00:00:00 2001 From: Viktor Verebelyi Date: Tue, 3 Apr 2018 15:24:31 +0100 Subject: [PATCH] Check if work queue is empty on cleanup --- bonjour.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bonjour.cpp b/bonjour.cpp index 1db7b7b..b046fbd 100644 --- a/bonjour.cpp +++ b/bonjour.cpp @@ -228,7 +228,8 @@ void QZeroConfPrivate::cleanUp(DNSServiceRef toClean) delete resolverSocket; resolverSocket = NULL; } - work.dequeue(); + if(!work.isEmpty()) + work.dequeue(); if (work.size()) resolve(); }