diff --git a/include/cutils/sockets.h b/include/cutils/sockets.h index b9c22c165..4626e7acd 100644 --- a/include/cutils/sockets.h +++ b/include/cutils/sockets.h @@ -84,7 +84,6 @@ int android_get_control_socket(const char* name); * * These functions return INVALID_SOCKET (-1) on failure for all platforms. */ -int socket_loopback_client(int port, int type); cutils_socket_t socket_network_client(const char* host, int port, int type); int socket_network_client_timeout(const char* host, int port, int type, int timeout, int* getaddrinfo_error); diff --git a/libcutils/Android.bp b/libcutils/Android.bp index 94275bd1e..943926b9b 100644 --- a/libcutils/Android.bp +++ b/libcutils/Android.bp @@ -23,7 +23,6 @@ libcutils_nonwindows_sources = [ "socket_inaddr_any_server_unix.c", "socket_local_client_unix.c", "socket_local_server_unix.c", - "socket_loopback_client_unix.c", "socket_loopback_server_unix.c", "socket_network_client_unix.c", "sockets_unix.cpp", diff --git a/libcutils/socket_loopback_client_unix.c b/libcutils/socket_loopback_client_unix.c deleted file mode 100644 index 137e369c2..000000000 --- a/libcutils/socket_loopback_client_unix.c +++ /dev/null @@ -1,40 +0,0 @@ -/* -** Copyright 2006, The Android Open Source Project -** -** 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. -*/ - -#include -#include -#include -#include -#include - -#if !defined(_WIN32) -#include -#include -#include -#include -#endif - -#include - -/* Connect to port on the loopback IP interface. type is - * SOCK_STREAM or SOCK_DGRAM. - * return is a file descriptor or -1 on error - */ -int socket_loopback_client(int port, int type) -{ - return socket_network_client("localhost", port, type); -} -