getifaddrs

Roland McGrath roland@redhat.com
Mon Nov 25 19:17:00 GMT 2002


Those changes would break GNU/Linux, where there is no sa_len field.  I
think it is harmless to allocate and copy a bit too much, so I just changed
ifaddrs.c to use struct sockaddr_storage and left the structure assignments
(so now they will copy more than needed, but always enough) rather than
complicating the code with conditional use of sa_len.

I've put in the changes to set the fields to null instead of failing when
the ioctls other that SIOCGIFFLAGS fail.



More information about the Libc-alpha mailing list