Skip to content

Commit

Permalink
remove callbacks before stopping tcp protocol layer (5.13) (#1696)
Browse files Browse the repository at this point in the history
  • Loading branch information
rex-schilasky authored Aug 7, 2024
1 parent ccc2bfe commit 72a8b5c
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions ecal/core/src/service/ecal_service_server_impl.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* ========================= eCAL LICENSE =================================
*
* Copyright (C) 2016 - 2019 Continental Corporation
* Copyright (C) 2016 - 2024 Continental Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -141,12 +141,6 @@ namespace eCAL
{
if (!m_created) return(false);

if (m_tcp_server_v0)
m_tcp_server_v0->stop();

if (m_tcp_server_v1)
m_tcp_server_v1->stop();

// reset method callback map
{
std::lock_guard<std::mutex> const lock(m_method_map_sync);
Expand All @@ -159,6 +153,12 @@ namespace eCAL
m_event_callback_map.clear();
}

if (m_tcp_server_v0)
m_tcp_server_v0->stop();

if (m_tcp_server_v1)
m_tcp_server_v1->stop();

// mark as no more created (and prevent reregistering)
m_created = false;

Expand Down

0 comments on commit 72a8b5c

Please sign in to comment.