Remove separate IPv4-only nsaddr_list from res_state
The res_state struct held two separate lists of nameserver addresses, presumably for binary compatibility with userspace poking directly at libc internal data structures. This change removes the IPv4 only statp->nsaddr_list and keeps the deeply-nested statp->_u._ext.ext->nsaddrs, which is a sockaddr_union. While cleaning up res_init, I had a wtf moment when I noticed that HAS_INET6_STRUCTS is never defined. So, we don't actually support v6 nameservers??? The truth is: we don't really use res_setservers() other than at initialization time, when it's a no-op, and res_getservers() was actually dead code. So they can both rest in peace. Test: m, flashall, atest Change-Id: Iba0d5aa73f531b5ed925eb4178e5d5883c12a23d
Loading
Please register or sign in to comment