From 211423d4320ee78e046edc7721f90c0837c21264 Mon Sep 17 00:00:00 2001 From: Mario Dominguez Date: Wed, 11 Dec 2024 10:47:31 +0100 Subject: [PATCH] Refs #22339: Take writer's mutex before rproxy->stop() and check_acked_status() Signed-off-by: Mario Dominguez --- src/cpp/rtps/writer/StatefulWriter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cpp/rtps/writer/StatefulWriter.cpp b/src/cpp/rtps/writer/StatefulWriter.cpp index 83c01a9098f..2e6970bb317 100644 --- a/src/cpp/rtps/writer/StatefulWriter.cpp +++ b/src/cpp/rtps/writer/StatefulWriter.cpp @@ -1217,9 +1217,9 @@ bool StatefulWriter::matched_reader_remove( const GUID_t& reader_guid) { ReaderProxy* rproxy = nullptr; + std::lock_guard lock(mp_mutex); { - std::lock_guard lock(mp_mutex); std::lock_guard guard_locator_selector_general(locator_selector_general_); std::lock_guard guard_locator_selector_async(locator_selector_async_);