From: Lars Ingebrigtsen <larsi@gnus.org>
Date: Sat, 30 Jan 2016 01:39:52 +0000 (+0100)
Subject: * process.c (check_for_dns): Free the result data.
X-Git-Tag: emacs-26.0.90~2520^2~61
X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0677d94e2d55d473e9bbacde009bfd83df0bc67e;p=emacs.git

* process.c (check_for_dns): Free the result data.
---

diff --git a/src/process.c b/src/process.c
index 90e18d72014..dafd5330d30 100644
--- a/src/process.c
+++ b/src/process.c
@@ -4563,12 +4563,14 @@ check_for_dns (Lisp_Object proc)
 	}
 
       ip_addresses = Fnreverse (ip_addresses);
+      freeaddrinfo (p->dns_request->ar_result);
+      /* Free the calling array, too? FIXME */
       connect_network_socket (proc, ip_addresses);
       return 1;
     }
 
   pset_status (p, Qfailed);
-  return 0;
+  return 1;
 }
 #endif /* HAVE_GETADDRINFO_A */