From b2c61f461fe92112dcc0d6ffc0c46ea3671294a7 Mon Sep 17 00:00:00 2001 From: Javier Santiago Date: Wed, 13 Jul 2022 09:38:58 +0200 Subject: [PATCH] Detach listener Signed-off-by: Javier Santiago --- rmw_fastrtps_shared_cpp/src/rmw_service.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/rmw_fastrtps_shared_cpp/src/rmw_service.cpp b/rmw_fastrtps_shared_cpp/src/rmw_service.cpp index 51af59baf..be6d2ad08 100644 --- a/rmw_fastrtps_shared_cpp/src/rmw_service.cpp +++ b/rmw_fastrtps_shared_cpp/src/rmw_service.cpp @@ -118,6 +118,7 @@ __rmw_destroy_service( show_previous_error(); RMW_SET_ERROR_MSG("Fail in delete datawriter"); final_ret = RMW_RET_ERROR; + info->response_writer_->set_listener(nullptr); } // Delete DataWriter listener