diff options
Diffstat (limited to 'src/client/ClientNew.cxx')
-rw-r--r-- | src/client/ClientNew.cxx | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/src/client/ClientNew.cxx b/src/client/ClientNew.cxx index d7fab2a9c..85ce97aa3 100644 --- a/src/client/ClientNew.cxx +++ b/src/client/ClientNew.cxx @@ -35,10 +35,6 @@ #include <sys/socket.h> #endif -#ifdef HAVE_LIBWRAP -#include <tcpd.h> -#endif - static constexpr char GREETING[] = "OK MPD " PROTOCOL_VERSION "\n"; Client::Client(EventLoop &_loop, Partition &_partition, @@ -66,27 +62,6 @@ client_new(EventLoop &loop, Partition &partition, assert(fd.IsDefined()); -#ifdef HAVE_LIBWRAP - if (address.GetFamily() != AF_LOCAL) { - // TODO: shall we obtain the program name from argv[0]? - const char *progname = "mpd"; - - struct request_info req; - request_init(&req, RQ_FILE, fd.Get(), RQ_DAEMON, progname, 0); - - fromhost(&req); - - if (!hosts_access(&req)) { - /* tcp wrappers says no */ - FormatWarning(client_domain, - "libwrap refused connection (libwrap=%s) from %s", - progname, remote.c_str()); - - return; - } - } -#endif /* HAVE_WRAP */ - ClientList &client_list = *partition.instance.client_list; if (client_list.IsFull()) { LogWarning(client_domain, "Max connections reached"); |