From aa227cded1fabeeeb0fc316207a1e7b1a5d89785 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 24 Feb 2021 20:30:54 +0100 Subject: [PATCH] input/qobuz: use class IntrusiveList --- src/input/plugins/QobuzClient.hxx | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/input/plugins/QobuzClient.hxx b/src/input/plugins/QobuzClient.hxx index 3b957a87e..54cfddfe1 100644 --- a/src/input/plugins/QobuzClient.hxx +++ b/src/input/plugins/QobuzClient.hxx @@ -25,15 +25,14 @@ #include "lib/curl/Init.hxx" #include "thread/Mutex.hxx" #include "event/DeferEvent.hxx" - -#include +#include "util/IntrusiveList.hxx" #include #include #include class QobuzSessionHandler - : public boost::intrusive::list_base_hook> + : public SafeLinkIntrusiveListHook { public: virtual void OnQobuzSession() noexcept = 0; @@ -59,8 +58,7 @@ class QobuzClient final : QobuzLoginHandler { std::exception_ptr error; - typedef boost::intrusive::list> LoginHandlerList; + using LoginHandlerList = IntrusiveList; LoginHandlerList handlers; @@ -87,7 +85,7 @@ public: void RemoveLoginHandler(QobuzSessionHandler &h) noexcept { const std::lock_guard protect(mutex); if (h.is_linked()) - handlers.erase(handlers.iterator_to(h)); + h.unlink(); } /**