Commit e2249d10 authored by Simon Morlat's avatar Simon Morlat
Browse files

remove stupid ipv6 info message at first startup

parent 9412a100
......@@ -496,10 +496,6 @@ static void sip_config_read(LinphoneCore *lc)
ipv6=lp_config_get_int(lc->config,"sip","use_ipv6",-1);
if (ipv6==-1){
ipv6=0;
if (host_has_ipv6_network()){
if (lc->vtable.display_message)
lc->vtable.display_message(lc,_("Your machine appears to be connected to an IPv6 network. By default linphone always uses IPv4. Please update your configuration if you want to use IPv6"));
}
}
linphone_core_enable_ipv6(lc,ipv6);
memset(&tr,0,sizeof(tr));
......
......@@ -345,52 +345,6 @@ bool_t lp_spawn_command_line_sync(const char *command, char **result,int *comman
return FALSE;
}
#if defined(HAVE_GETIFADDRS) && defined(INET6)
#include <sys/types.h>
#include <sys/socket.h>
#include <ifaddrs.h>
bool_t host_has_ipv6_network()
{
struct ifaddrs *ifp;
struct ifaddrs *ifpstart;
bool_t ipv6_present=FALSE;
if (getifaddrs (&ifpstart) < 0)
{
return FALSE;
}
for (ifp=ifpstart; ifp != NULL; ifp = ifp->ifa_next)
{
if (!ifp->ifa_addr)
continue;
switch (ifp->ifa_addr->sa_family) {
case AF_INET:
break;
case AF_INET6:
ipv6_present=TRUE;
break;
default:
continue;
}
}
freeifaddrs (ifpstart);
return ipv6_present;
}
#else
bool_t host_has_ipv6_network()
{
return FALSE;
}
#endif
static ortp_socket_t create_socket(int local_port){
struct sockaddr_in laddr;
ortp_socket_t sock;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment