From 0a516ea6f5528e7ce38a7ae40379cd778e89ff33 Mon Sep 17 00:00:00 2001 From: rohit Date: Tue, 3 Apr 2018 15:27:19 -0700 Subject: [PATCH] Corrected indentation --- rmw_fastrtps_cpp/src/rmw_client.cpp | 18 ++++++++---------- rmw_fastrtps_cpp/src/rmw_publisher.cpp | 9 ++++----- rmw_fastrtps_cpp/src/rmw_service.cpp | 18 ++++++++---------- rmw_fastrtps_cpp/src/rmw_subscription.cpp | 9 ++++----- 4 files changed, 24 insertions(+), 30 deletions(-) diff --git a/rmw_fastrtps_cpp/src/rmw_client.cpp b/rmw_fastrtps_cpp/src/rmw_client.cpp index 822fc2380..66f055531 100644 --- a/rmw_fastrtps_cpp/src/rmw_client.cpp +++ b/rmw_fastrtps_cpp/src/rmw_client.cpp @@ -122,11 +122,10 @@ rmw_create_client( subscriberParam.topic.topicKind = NO_KEY; subscriberParam.topic.topicDataType = response_type_name; subscriberParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; - if (!qos_policies->avoid_ros_namespace_conventions){ - subscriberParam.topic.topicName = std::string(ros_service_response_prefix) + service_name; - } - else{ - subscriberParam.topic.topicName = service_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + subscriberParam.topic.topicName = std::string(ros_service_response_prefix) + service_name; + } else { + subscriberParam.topic.topicName = service_name; } subscriberParam.topic.topicName += "Reply"; @@ -134,11 +133,10 @@ rmw_create_client( publisherParam.topic.topicDataType = request_type_name; publisherParam.qos.m_publishMode.kind = ASYNCHRONOUS_PUBLISH_MODE; publisherParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; - if (!qos_policies->avoid_ros_namespace_conventions){ - publisherParam.topic.topicName = std::string(ros_service_requester_prefix) + service_name; - } - else{ - publisherParam.topic.topicName = service_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + publisherParam.topic.topicName = std::string(ros_service_requester_prefix) + service_name; + } else { + publisherParam.topic.topicName = service_name; } publisherParam.topic.topicName += "Request"; diff --git a/rmw_fastrtps_cpp/src/rmw_publisher.cpp b/rmw_fastrtps_cpp/src/rmw_publisher.cpp index 2a2f6f5b5..07c675e1c 100644 --- a/rmw_fastrtps_cpp/src/rmw_publisher.cpp +++ b/rmw_fastrtps_cpp/src/rmw_publisher.cpp @@ -102,11 +102,10 @@ rmw_create_publisher( publisherParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; publisherParam.topic.topicKind = NO_KEY; publisherParam.topic.topicDataType = type_name; - if (!qos_policies->avoid_ros_namespace_conventions){ - publisherParam.topic.topicName = std::string(ros_topic_prefix) + topic_name; - } - else{ - publisherParam.topic.topicName = topic_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + publisherParam.topic.topicName = std::string(ros_topic_prefix) + topic_name; + } else { + publisherParam.topic.topicName = topic_name; } #if HAVE_SECURITY diff --git a/rmw_fastrtps_cpp/src/rmw_service.cpp b/rmw_fastrtps_cpp/src/rmw_service.cpp index 1c6dd104c..ffcec9c47 100644 --- a/rmw_fastrtps_cpp/src/rmw_service.cpp +++ b/rmw_fastrtps_cpp/src/rmw_service.cpp @@ -133,11 +133,10 @@ rmw_create_service( subscriberParam.topic.topicKind = NO_KEY; subscriberParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; subscriberParam.topic.topicDataType = request_type_name; - if (!qos_policies->avoid_ros_namespace_conventions){ - subscriberParam.topic.topicName = std::string(ros_service_requester_prefix) + service_name; - } - else{ - subscriberParam.topic.topicName = service_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + subscriberParam.topic.topicName = std::string(ros_service_requester_prefix) + service_name; + } else { + subscriberParam.topic.topicName = service_name; } subscriberParam.topic.topicName += "Request"; @@ -145,11 +144,10 @@ rmw_create_service( publisherParam.topic.topicDataType = response_type_name; publisherParam.qos.m_publishMode.kind = ASYNCHRONOUS_PUBLISH_MODE; publisherParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; - if (!qos_policies->avoid_ros_namespace_conventions){ - publisherParam.topic.topicName = std::string(ros_service_response_prefix) + service_name; - } - else{ - publisherParam.topic.topicName = service_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + publisherParam.topic.topicName = std::string(ros_service_response_prefix) + service_name; + } else { + publisherParam.topic.topicName = service_name; } publisherParam.topic.topicName += "Reply"; diff --git a/rmw_fastrtps_cpp/src/rmw_subscription.cpp b/rmw_fastrtps_cpp/src/rmw_subscription.cpp index d7fca6475..0341c14ba 100644 --- a/rmw_fastrtps_cpp/src/rmw_subscription.cpp +++ b/rmw_fastrtps_cpp/src/rmw_subscription.cpp @@ -104,11 +104,10 @@ rmw_create_subscription( subscriberParam.historyMemoryPolicy = PREALLOCATED_WITH_REALLOC_MEMORY_MODE; subscriberParam.topic.topicKind = NO_KEY; subscriberParam.topic.topicDataType = type_name; - if (!qos_policies->avoid_ros_namespace_conventions){ - subscriberParam.topic.topicName = std::string(ros_topic_prefix) + topic_name; - } - else{ - subscriberParam.topic.topicName = topic_name; + if (!qos_policies->avoid_ros_namespace_conventions) { + subscriberParam.topic.topicName = std::string(ros_topic_prefix) + topic_name; + } else { + subscriberParam.topic.topicName = topic_name; } #if HAVE_SECURITY