]> git.ipfire.org Git - thirdparty/libvirt.git/commit
Remove all use of inet_pton and inet_ntop
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 21 Oct 2010 10:13:05 +0000 (11:13 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 22 Oct 2010 10:59:18 +0000 (11:59 +0100)
commita8ae7d19f4ace62ff3f364c628cbc16baa9b080c
tree0120a9fbe136aef3715c8b1ab07dee26e945973a
parent640c5f1984d3a7c88e43bdcc0b6320a18e39b532
Remove all use of inet_pton and inet_ntop

The  inet_pton and inet_ntop functions are obsolete, replaced
by getaddrinfo+getnameinfo with the AI_NUMERICHOST flag set.
These can be accessed via the virSocket APIs.

The bridge.c code had methods for fetching the IP address of
a bridge which used inet_ntop. Aside from the use of inet_ntop
these methods are broken, because a NIC can have multiple
addresses and this only returns one address. Since the methods
are never used, just remove them.

* src/conf/network_conf.c, src/nwfilter/nwfilter_learnipaddr.c:
  Replace inet_pton and inet_ntop with virSocket APIs
* src/util/bridge.c, src/util/bridge.h: Remove unused methods
  which called inet_ntop.
src/conf/network_conf.c
src/nwfilter/nwfilter_learnipaddr.c
src/util/bridge.c
src/util/bridge.h