]> git.pld-linux.org Git - packages/proftpd.git/commitdiff
outdated
authorJan Rękorajski <baggins@pld-linux.org>
Thu, 8 Aug 2002 19:36:58 +0000 (19:36 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    proftpd-v6_fix.patch -> 1.3

proftpd-v6_fix.patch [deleted file]

diff --git a/proftpd-v6_fix.patch b/proftpd-v6_fix.patch
deleted file mode 100644 (file)
index 6f152a3..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
---- ./src/inet.c.org   Mon Oct 22 01:22:33 2001
-+++ ./src/inet.c       Mon Oct 22 01:29:14 2001
-@@ -211,60 +211,27 @@
-  * memory.
-  */
--char *inet_ascii(pool *pool, p_in_addr_t *addr)
-+char *inet_ascii(pool *pool, struct sockaddr_storage *addr)
- {
-   char *res = NULL;
--  if((res = inet_ntoa(*addr)) != NULL)
-+  if((res = INET_NTOA(addr)) != NULL)
-     res = pstrdup(pool,res);
-   return res;
- }
- /* Given an ip addresses, return the FQDN */
--char *inet_getname(pool *pool, p_in_addr_t *addr)
-+char *inet_getname(pool *pool, struct sockaddr_storage *addr)
- {
-+      char name[1025] = {'\0'};
-   char *res = NULL;
-   char **checkaddr;
--  struct hostent *hptr_rev = NULL, *hptr_forw = NULL;
-   static char *res_cache = NULL;
--  static p_in_addr_t *addr_cache = NULL;
--  if(reverse_dns) {
--    if(res_cache && addr_cache && addr_cache->s_addr == addr->s_addr) {
--      res = pstrdup(pool, res_cache);
--      return inet_validate(res);
--    }
--    
--    if((hptr_rev = gethostbyaddr((const char *)addr,
--                                 sizeof(p_in_addr_t), AF_INET)) != NULL) {
--      if((hptr_forw = gethostbyname(hptr_rev->h_name)) != NULL) {
--        for(checkaddr = hptr_forw->h_addr_list; *checkaddr; ++checkaddr) {
--          if(((p_in_addr_t*)(*checkaddr))->s_addr == addr->s_addr) {
--            res = pstrdup(pool, hptr_rev->h_name);
--            break;
--          }
--        }
--      }
--    }
--  }
--  
--  if(!res)
--    res = pstrdup(pool, inet_ntoa(*addr));
-- 
--  if(reverse_dns) {
--    /* cache the result */
--    if(!addr_cache)
--      addr_cache = malloc(sizeof(p_in_addr_t));
--
--    if(addr_cache)
--      memcpy(addr_cache, addr, sizeof(p_in_addr_t));
--
--    if(res_cache)
--      free(res_cache);
--
--    res_cache = strdup(res);
--  }
-+  getnameinfo((struct sockaddr *)addr, sizeof(struct sockaddr_storage),
-+                name, sizeof(name), NULL, 0, 0);
-+  res = pstrdup(pool, name);
-   
-   return inet_validate(res);
- }
This page took 0.135419 seconds and 4 git commands to generate.