On Fri, Mar 25, 2016 at 1:00 PM, Richard Levitte via RT <r...@openssl.org> wrote: > Vid Fre, 25 Mar 2016 kl. 10.29.39, skrev noloa...@gmail.com: >> gcc -DDSO_DLFCN -DHAVE_DLFCN_H -DOPENSSL_THREADS >> -DOPENSSL_NO_STATIC_ENGINE -DOPENSSL_PIC >> -DOPENSSLDIR="\"/usr/local/ssl\"" >> -DENGINESDIR="\"/usr/local/lib/engines\"" -Wall -O3 -pthread -m64 >> -DL_ENDIAN -ansi -fPIC -Iinclude -I. -Icrypto/include -MMD -MF >> crypto/bio/bss_dgram.d.tmp -MT crypto/bio/bss_dgram.o -c -o >> crypto/bio/bss_dgram.o crypto/bio/bss_dgram.c >> In file included from /usr/include/netdb.h:27:0, >> from ./e_os.h:443, >> from crypto/bio/bio_lcl.h:2, >> from crypto/bio/bss_dgram.c:62: >> crypto/bio/bss_dgram.c: In function ‘dgram_get_mtu_overhead’: >> crypto/bio/bss_dgram.c:433:20: error: ‘const struct in6_addr’ has no >> member named ‘s6_addr32’ >> && IN6_IS_ADDR_V4MAPPED(&tmp_addr)) >> ^ >> crypto/bio/bss_dgram.c:433:20: error: ‘const struct in6_addr’ has no >> member named ‘s6_addr32’ > > This is particularly disturbing... It suggests that the diverse network system > headers have bugs under certain circumstances...
Yeah, I did not quite understand it either. I think its because ANSI, POSIX, et al only require a 'struct in6_addr'. They don't require the other members. Looking at the two definitions of in6_addr showed both guarded the additional members. The following is from a mostly GNU Linux machine (Ubuntu): Here one (/usr/include/linux/in6.h): #if __UAPI_DEF_IN6_ADDR struct in6_addr { union { __u8 u6_addr8[16]; #if __UAPI_DEF_IN6_ADDR_ALT __be16 u6_addr16[8]; __be32 u6_addr32[4]; #endif } in6_u; #define s6_addr in6_u.u6_addr8 #if __UAPI_DEF_IN6_ADDR_ALT #define s6_addr16 in6_u.u6_addr16 #define s6_addr32 in6_u.u6_addr32 #endif }; #endif /* __UAPI_DEF_IN6_ADDR */ And here's the other (/usr/include/netinet/in.h): #ifndef __USE_KERNEL_IPV6_DEFS /* IPv6 address */ struct in6_addr { union { uint8_t __u6_addr8[16]; #ifdef __USE_MISC uint16_t __u6_addr16[8]; uint32_t __u6_addr32[4]; #endif } __in6_u; #define s6_addr __in6_u.__u6_addr8 #ifdef __USE_MISC # define s6_addr16 __in6_u.__u6_addr16 # define s6_addr32 __in6_u.__u6_addr32 #endif }; #endif /* !__USE_KERNEL_IPV6_DEFS */ Jeff -- Ticket here: http://rt.openssl.org/Ticket/Display.html?id=4480 Please log in as guest with password guest if prompted -- openssl-dev mailing list To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-dev