upnp: fix shutdown issues

GitLab: #21
GitLab: #28
Change-Id: I1c8e0ba00139b516ab964f8e0be76b571bd47534
diff --git a/src/upnp/protocol/pupnp/pupnp.h b/src/upnp/protocol/pupnp/pupnp.h
index 7deb4fb..03086dd 100644
--- a/src/upnp/protocol/pupnp/pupnp.h
+++ b/src/upnp/protocol/pupnp/pupnp.h
@@ -26,6 +26,7 @@
 #include "upnp_igd.h"
 #include "ip_utils.h"
 
+#include <opendht/thread_pool.h>
 #include <upnp/upnp.h>
 #include <upnp/upnptools.h>
 
@@ -246,9 +247,9 @@
 
     // Count ongoing operations
     std::mutex ongoingOpsMtx_;
-    std::condition_variable cvOngoing_;
     int ongoingOps_ {0};
     bool destroying_ {false};
+    dht::ThreadPool ongoingOpsThreadPool_;
 };
 
 } // namespace upnp