mirror of
https://github.com/micro-ROS/micro-ROS-Agent.git
synced 2026-09-06 18:05:17 +02:00
Keep graph manager alive until destruction
This commit is contained in:
@@ -80,17 +80,15 @@ public:
|
||||
/**
|
||||
* @brief Default destructor.
|
||||
*/
|
||||
~GraphManager() = default;
|
||||
|
||||
void stop()
|
||||
{
|
||||
if (microros_graph_publisher_.joinable())
|
||||
{
|
||||
exit = true;
|
||||
cv_.notify_one();
|
||||
microros_graph_publisher_.join();
|
||||
}
|
||||
}
|
||||
~GraphManager()
|
||||
{
|
||||
if (microros_graph_publisher_.joinable())
|
||||
{
|
||||
exit = true;
|
||||
cv_.notify_one();
|
||||
microros_graph_publisher_.join();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Implementation of the notification logic that updates the micro-ROS graph.
|
||||
|
||||
Reference in New Issue
Block a user