Skip to content

Commit

Permalink
Update rmw_context_impl_t definition (#300)
Browse files Browse the repository at this point in the history
Signed-off-by: Christophe Bedard <[email protected]>
  • Loading branch information
christophebedard authored Sep 15, 2021
1 parent d54704d commit ba3fe6f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions rmw_email_cpp/include/rmw_email_cpp/types.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "email/wait_set.hpp"
#include "rmw/rmw.h"

struct rmw_context_impl_t
struct rmw_context_impl_s
{
// TODO(christophebedard) move to graph cache handler?
rmw_guard_condition_t * graph_guard_condition{nullptr};
Expand All @@ -36,10 +36,10 @@ struct rmw_context_impl_t

bool is_shutdown{false};

rmw_context_impl_t();
rmw_context_impl_s();

/// Context destruction, called when deleting this.
~rmw_context_impl_t();
~rmw_context_impl_s();

/// Called whenever a new node is created.
rmw_ret_t
Expand Down
10 changes: 5 additions & 5 deletions rmw_email_cpp/src/rmw_init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,12 @@ extern "C" rmw_ret_t rmw_init_options_fini(rmw_init_options_t * init_options)
return ret;
}

rmw_context_impl_t::rmw_context_impl_t()
rmw_context_impl_s::rmw_context_impl_s()
{
RMW_EMAIL_LOG_DEBUG("initializing context implementation");
}

rmw_context_impl_t::~rmw_context_impl_t()
rmw_context_impl_s::~rmw_context_impl_s()
{
RMW_EMAIL_LOG_DEBUG("shutting down context implementation");
// Shutdown middleware
Expand All @@ -124,7 +124,7 @@ rmw_context_impl_t::~rmw_context_impl_t()
}

rmw_ret_t
rmw_context_impl_t::init(rmw_init_options_t * options, size_t domain_id)
rmw_context_impl_s::init(rmw_init_options_t * options, size_t domain_id)
{
static_cast<void>(options);
// There's no concept of "domain" with email, duh
Expand Down Expand Up @@ -159,7 +159,7 @@ rmw_context_impl_t::init(rmw_init_options_t * options, size_t domain_id)
}

rmw_ret_t
rmw_context_impl_t::fini()
rmw_context_impl_s::fini()
{
std::scoped_lock<std::mutex> lock(mutex_initialization);
if (0u != --this->node_count) {
Expand All @@ -171,7 +171,7 @@ rmw_context_impl_t::fini()
}

void
rmw_context_impl_t::cleanup()
rmw_context_impl_s::cleanup()
{
if (this->graph_guard_condition) {
rmw_email_cpp::destroy_guard_condition(this->graph_guard_condition);
Expand Down

0 comments on commit ba3fe6f

Please sign in to comment.