]> granicus.if.org Git - libtirpc/commitdiff
Fix compile error: 'IPPORT_RESERVED' undeclared
authorNatanael Copa <ncopa@alpinelinux.org>
Wed, 22 Apr 2015 16:26:14 +0000 (12:26 -0400)
committerSteve Dickson <steved@redhat.com>
Thu, 23 Apr 2015 12:29:45 +0000 (08:29 -0400)
The IPPORT_RESERVED is declared in netdb.h. This fixes the following
compile error with musl libc:

bindresvport.c: In function 'bindresvport_sa':
bindresvport.c:67:18: error: 'IPPORT_RESERVED' undeclared (first use in
this function)
 #define ENDPORT (IPPORT_RESERVED - 1)
                   ^
Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
src/bindresvport.c

index d6d9c149e2108770411a4ee1735a086700d11fd3..5a7a1a92c27c37db2715156e33e9471de082903a 100644 (file)
@@ -37,6 +37,7 @@
 #include <sys/types.h>
 #include <sys/socket.h>
 
+#include <netdb.h>
 #include <netinet/in.h>
 
 #include <errno.h>