[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Linphone-developers] [patch] better local ip detection routine in LAN c
[Linphone-developers] [patch] better local ip detection routine in LAN cases
Fri, 26 Oct 2007 15:04:53 -0400
if you run linphone on a LAN that has no sort of routing set up, then
the attempt to autodetect the outgoing IP address will fail miserably
and linphone falls back to just "127.0.0.1" which is pretty useless.
the attached code uses the POSIX function if_nameindex() to enumerate
the available interfaces on the machine and then the Linux ioctl
SIOCGIFADDR to get the ip address associated with the specified
interface. if someone knows of a POSIX equivalent to this ioctl, i'm
all ears ;). so now linphone defaults to the first non-loopback
interface that contains a valid ip address in the case of autodetect
enabled and running on a non-external routable network.
the patch was tested against linphone-1.6.0 but it applies cleanly to 1.7.1.
Description: Text Data
|[Prev in Thread]
||[Next in Thread]|
- [Linphone-developers] [patch] better local ip detection routine in LAN cases,
Mike Frysinger <=