* added tear-down of node sub-interfaces in reverse order of their creation (#1469) Signed-off-by: Colin MacKenzie <colin@flyingeinstein.com> * added name of service to log message for leak detection. Previously it gave no indication of what node is causing the memory leak (#1469) Signed-off-by: Colin MacKenzie <colin@flyingeinstein.com> (cherry picked from commit b9ffd72f42ae44352256f2eab585299bf85c6346) Co-authored-by: Colin MacKenzie <guru-florida@users.noreply.github.com>
This commit is contained in:
parent
dc3832c4ec
commit
92fe787a74
3 changed files with 28 additions and 6 deletions
|
@ -126,7 +126,18 @@ LifecycleNode::LifecycleNode(
|
|||
}
|
||||
|
||||
LifecycleNode::~LifecycleNode()
|
||||
{}
|
||||
{
|
||||
// release sub-interfaces in an order that allows them to consult with node_base during tear-down
|
||||
node_waitables_.reset();
|
||||
node_time_source_.reset();
|
||||
node_parameters_.reset();
|
||||
node_clock_.reset();
|
||||
node_services_.reset();
|
||||
node_topics_.reset();
|
||||
node_timers_.reset();
|
||||
node_logging_.reset();
|
||||
node_graph_.reset();
|
||||
}
|
||||
|
||||
const char *
|
||||
LifecycleNode::get_name() const
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue