svn commit: samba r25472 - in branches: SAMBA_3_2/source SAMBA_3_2/source/include SAMBA_3_2/source/lib SAMBA_3_2/source/lib/replace SAMBA_3_2/source/lib/replace/system SAMBA_3_2/source/utils SAMBA_3_2_0/source SAMBA_3_2_0/source/include SAMBA_3_2_0/source/lib SAMBA_3_2_0/source/lib/replace SAMBA_3_2_0/source/lib/replace/system SAMBA_3_2_0/source/utils

Jeremy Allison jra at
Tue Oct 2 21:17:06 GMT 2007

On Tue, Oct 02, 2007 at 10:11:40PM +0100, David Holder wrote:
> Jeremy,
> I agree it seems like the way to go. I've not tried getifaddrs on 
> systems other than Linux, it will be interesting to see if it works.

I found the interface (it's not documeted in my Linux man pages)
by searching for code to enumerate IPv6 addresses - the person
writing about it claimed it works on Linux and MaxOSX - two of
our most popular platforms.

On older/stranger systems we with IPv6 we can add to the existing
lib/interfaces.c code which tests a bunch of different API's and
add to this as we find means that work for enumerating all addresses
on all interfaces. We use this approach for the dfree and quotas
code in Samba - it's ugly but for such a platform-specific thing
sometimes it's the best we can do.

Now to fix up all the inet_ntoa -> inet_ntop calls :-).


More information about the samba-technical mailing list