summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorBernd Kuhls <bernd.kuhls@t-online.de>2017-09-13 14:07:11 +0200
committerBernd Kuhls <bernd.kuhls@t-online.de>2017-09-13 14:07:11 +0200
commit543f44bff8d56785dc13a74a14d4eaa96465bf05 (patch)
tree62181d594716ba3b728064aba83378ca542c093d /src
parentbc728f92de5aca1ae14c51696e35103b77a71657 (diff)
downloadngircd-543f44bff8d56785dc13a74a14d4eaa96465bf05.tar.gz
ngircd-543f44bff8d56785dc13a74a14d4eaa96465bf05.zip
Fix Get_error usage
The usage of Get_Error is guarded by "ifdef h_errno" in this file, the
definition of this function should follow the same rules.

Fixes a build error when cross-compiling:
https://github.com/ngircd/ngircd/issues/223
Diffstat (limited to 'src')
-rw-r--r--src/ngircd/resolve.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/ngircd/resolve.c b/src/ngircd/resolve.c
index 32791901..e1903254 100644
--- a/src/ngircd/resolve.c
+++ b/src/ngircd/resolve.c
@@ -108,9 +108,7 @@ Resolve_Name( PROC_STAT *s, const char *Host, void (*cbfunc)(int, short))
 	return false;
 } /* Resolve_Name */
 
-
-#if !defined(HAVE_GETADDRINFO) || !defined(HAVE_GETNAMEINFO)
-#if !defined(WANT_IPV6) && defined(h_errno)
+#ifdef h_errno
 static char *
 Get_Error( int H_Error )
 {
@@ -128,7 +126,6 @@ Get_Error( int H_Error )
 	return "unknown error";
 }
 #endif
-#endif
 
 
 /* Do "IDENT" (aka "AUTH") lookup and append result to resolved_addr array */