From 4ff4d2119f2f830b4a0c31de7003cf4dcbc9930b Mon Sep 17 00:00:00 2001 From: dhood Date: Wed, 21 Feb 2018 16:13:11 -0800 Subject: [PATCH] Don't hard-code logger name separator --- rcl/src/rcl/node.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rcl/src/rcl/node.c b/rcl/src/rcl/node.c index fc50e765c..0b701990d 100644 --- a/rcl/src/rcl/node.c +++ b/rcl/src/rcl/node.c @@ -84,7 +84,7 @@ const char * rcl_create_node_logger_name( // i.e. it will start with a forward slash, which we want to ignore. const char * ns_with_separators = rcutils_repl_str( node_namespace + 1, // Ignore the leading forward slash. - "/", ".", + "/", RCUTILS_LOGGING_SEPARATOR_STRING, (rcl_allocator_t *)allocator); // TODO(dhood): remove need for casting away const if (NULL == ns_with_separators) { return NULL; @@ -92,7 +92,7 @@ const char * rcl_create_node_logger_name( // Join the namespace and node name to create the logger name. char * node_logger_name = rcutils_format_string( - *allocator, "%s.%s", ns_with_separators, node_name); + *allocator, "%s%s%s", ns_with_separators, RCUTILS_LOGGING_SEPARATOR_STRING, node_name); if (NULL == node_logger_name) { allocator->deallocate((char *)ns_with_separators, allocator->state); return NULL;