From 69952807cfa9478da0b76b9bca04e334c29bc10f Mon Sep 17 00:00:00 2001 From: Tomoya Fujita Date: Mon, 29 Jul 2024 00:50:22 -0700 Subject: [PATCH] remove rmw_localhost_only_t. (#376) Signed-off-by: Tomoya Fujita --- rmw/include/rmw/init_options.h | 3 --- rmw/include/rmw/localhost.h | 40 ---------------------------------- rmw/src/init_options.c | 2 -- 3 files changed, 45 deletions(-) delete mode 100644 rmw/include/rmw/localhost.h diff --git a/rmw/include/rmw/init_options.h b/rmw/include/rmw/init_options.h index 2f3031f3..1844b8e0 100644 --- a/rmw/include/rmw/init_options.h +++ b/rmw/include/rmw/init_options.h @@ -25,7 +25,6 @@ extern "C" #include "rcutils/allocator.h" #include "rmw/discovery_options.h" #include "rmw/domain_id.h" -#include "rmw/localhost.h" #include "rmw/macros.h" #include "rmw/ret_types.h" #include "rmw/security_options.h" @@ -53,8 +52,6 @@ typedef struct RMW_PUBLIC_TYPE rmw_init_options_s size_t domain_id; /// Security options rmw_security_options_t security_options; - /// Enable localhost only - rmw_localhost_only_t localhost_only; /// Configure discovery rmw_discovery_options_t discovery_options; /// Enclave, name used to find security artifacts in a sros2 keystore. diff --git a/rmw/include/rmw/localhost.h b/rmw/include/rmw/localhost.h deleted file mode 100644 index 6d867fde..00000000 --- a/rmw/include/rmw/localhost.h +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2019 Open Source Robotics Foundation, Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef RMW__LOCALHOST_H_ -#define RMW__LOCALHOST_H_ - -#include "rmw/visibility_control.h" - -#ifdef __cplusplus -extern "C" -{ -#endif - -/// Used to specify if the context can only communicate through localhost. -typedef enum RMW_PUBLIC_TYPE rmw_localhost_only_e -{ - /// Uses ROS_LOCALHOST_ONLY environment variable. - RMW_LOCALHOST_ONLY_DEFAULT = 0, - /// Forces using only localhost. - RMW_LOCALHOST_ONLY_ENABLED = 1, - /// Forces disabling localhost only. - RMW_LOCALHOST_ONLY_DISABLED = 2, -} rmw_localhost_only_t; - -#ifdef __cplusplus -} -#endif - -#endif // RMW__LOCALHOST_H_ diff --git a/rmw/src/init_options.c b/rmw/src/init_options.c index ee26721c..f9c78482 100644 --- a/rmw/src/init_options.c +++ b/rmw/src/init_options.c @@ -15,7 +15,6 @@ #include #include "rmw/init_options.h" -#include "rmw/localhost.h" #include "rmw/discovery_options.h" #ifdef __cplusplus @@ -28,7 +27,6 @@ rmw_get_zero_initialized_init_options(void) { return (const rmw_init_options_t) { .domain_id = RMW_DEFAULT_DOMAIN_ID, - .localhost_only = RMW_LOCALHOST_ONLY_DEFAULT, .discovery_options = rmw_get_zero_initialized_discovery_options(), .implementation_identifier = NULL, .impl = NULL,