From 6a3b48d4f0045d9c6129458d91f6fab8ff415014 Mon Sep 17 00:00:00 2001 From: Norbert Federa Date: Wed, 15 Jun 2016 18:01:38 +0200 Subject: [PATCH] freerdp: remove static inet_ntop inet_ntop is already implemented in winpr --- libfreerdp/core/listener.c | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/libfreerdp/core/listener.c b/libfreerdp/core/listener.c index 262308269..2381c5f46 100644 --- a/libfreerdp/core/listener.c +++ b/libfreerdp/core/listener.c @@ -48,36 +48,6 @@ #define TAG FREERDP_TAG("core.listener") -#ifdef _WIN32 -#if _WIN32_WINNT < 0x0600 -static const char* inet_ntop(int af, const void* src, char* dst, size_t cnt) -{ - if (af == AF_INET) - { - struct sockaddr_in in; - - memset(&in, 0, sizeof(in)); - in.sin_family = AF_INET; - memcpy(&in.sin_addr, src, sizeof(struct in_addr)); - getnameinfo((struct sockaddr *)&in, sizeof(struct sockaddr_in), dst, cnt, NULL, 0, NI_NUMERICHOST); - return dst; - } - else if (af == AF_INET6) - { - struct sockaddr_in6 in; - - memset(&in, 0, sizeof(in)); - in.sin6_family = AF_INET6; - memcpy(&in.sin6_addr, src, sizeof(struct in_addr6)); - getnameinfo((struct sockaddr*) &in, sizeof(struct sockaddr_in6), dst, cnt, NULL, 0, NI_NUMERICHOST); - return dst; - } - - return NULL; -} -#endif -#endif - static BOOL freerdp_listener_open(freerdp_listener* instance, const char* bind_address, UINT16 port) { int status;