diff --git a/include/ros1_bridge/factory.hpp b/include/ros1_bridge/factory.hpp index 008316e8..eebb9df9 100755 --- a/include/ros1_bridge/factory.hpp +++ b/include/ros1_bridge/factory.hpp @@ -163,7 +163,7 @@ class Factory : public FactoryInterface return; // do not publish messages from bridge itself } } else { - auto msg = std::string("Failed to compare gids: ") + rmw_get_error_string_safe(); + auto msg = std::string("Failed to compare gids: ") + rmw_get_error_string().str; rmw_reset_error(); throw std::runtime_error(msg); }