1667. [port] linux: not all versions have IF_NAMESIZE.
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
1667. [port] linux: not all versions have IF_NAMESIZE.
|
||||
|
||||
1666. [bug] The optional port on hostnames in dual-stack-servers
|
||||
was being ignored.
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: ifiter_ioctl.c,v 1.46 2004/05/06 03:16:07 marka Exp $ */
|
||||
/* $Id: ifiter_ioctl.c,v 1.47 2004/06/19 00:48:15 marka Exp $ */
|
||||
|
||||
/*
|
||||
* Obtain the list of network interfaces using the SIOCGLIFCONF ioctl.
|
||||
@@ -100,6 +100,16 @@ struct isc_interfaceiter {
|
||||
#define IFCONF_BUFSIZE_INITIAL 4096
|
||||
#define IFCONF_BUFSIZE_MAX 1048576
|
||||
|
||||
#ifdef __linux
|
||||
#ifndef IF_NAMESIZE
|
||||
# ifdef IFNAMSIZ
|
||||
# define IF_NAMESIZE IFNAMSIZ
|
||||
# else
|
||||
# define IF_NAMESIZE 16
|
||||
# endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
static isc_result_t
|
||||
getbuf4(isc_interfaceiter_t *iter) {
|
||||
char strbuf[ISC_STRERRORSIZE];
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: interfaceiter.c,v 1.36 2004/04/20 06:46:46 marka Exp $ */
|
||||
/* $Id: interfaceiter.c,v 1.37 2004/06/19 00:48:15 marka Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
@@ -65,6 +65,11 @@ get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src,
|
||||
{
|
||||
struct sockaddr_in6 *sa6;
|
||||
|
||||
#if !defined(ISC_PLATFORM_HAVEIFNAMETOINDEX) || \
|
||||
!defined(ISC_PLATFORM_HAVESCOPEID)
|
||||
UNUSED(ifname);
|
||||
#endif
|
||||
|
||||
/* clear any remaining value for safety */
|
||||
memset(dst, 0, sizeof(*dst));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user