]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/resolve.c
Don't access already freed memory in IRC_KILL()
[ngircd-alex.git] / src / ngircd / resolve.c
index b1487beff7bf7a8ee89b28f3913afe57ac26ebd6..bccf5180f65ce0b839db30e28105986d40d49f85 100644 (file)
@@ -144,8 +144,8 @@ Resolve_Init(RES_STAT *s)
 }
 
 
-#ifndef WANT_IPV6
-#ifdef h_errno
+#if !defined(HAVE_GETADDRINFO) || !defined(HAVE_GETNAMEINFO)
+#if !defined(WANT_IPV6) && defined(h_errno)
 static char *
 Get_Error( int H_Error )
 {
@@ -162,8 +162,8 @@ Get_Error( int H_Error )
        }
        return "unknown error";
 }
-#endif /* h_errno */
-#endif /* WANT_IPV6 */
+#endif
+#endif
 
 
 /* Do "IDENT" (aka "AUTH") lookup and append result to resolved_addr array */
@@ -203,7 +203,7 @@ Do_IdentQuery(int identsock, array *resolved_addr)
  * the IP address in resbuf and returns false.
  * @param IpAddr ip address to resolve
  * @param resbuf result buffer to store DNS name/string representation of ip address
- * @reslen size of result buffer (must be >= NGT_INET_ADDRSTRLEN)
+ * @param reslen size of result buffer (must be >= NGT_INET_ADDRSTRLEN)
  * @return true if reverse lookup successful, false otherwise
  */
 static bool