From 22e2659c2f490cfe5bdf6dd604c160fe69a69f57 Mon Sep 17 00:00:00 2001 From: Stefan Becker Date: Fri, 15 Aug 2014 19:33:10 +0300 Subject: [PATCH] Fix #258: V&V call gets rejected when IPv6 is enabled (III) With commit 23b1c820a5dfdb3475c0da21edadedf669a11298 the original fix became a no-op. Partially revert it. --- src/core/sdpmsg.h | 2 +- src/core/sipe-media.c | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/core/sdpmsg.h b/src/core/sdpmsg.h index 9732447e..1336901b 100644 --- a/src/core/sdpmsg.h +++ b/src/core/sdpmsg.h @@ -44,7 +44,7 @@ struct sdpcandidate { SipeCandidateType type; SipeNetworkProtocol protocol; guint32 priority; - gchar *ip; /* this can be an IPv4 or IPv6 address */ + gchar *ip; /* currently this has to be an IPv4 address */ guint port; gchar *base_ip; guint base_port; diff --git a/src/core/sipe-media.c b/src/core/sipe-media.c index 9ece1f7a..a477ce77 100644 --- a/src/core/sipe-media.c +++ b/src/core/sipe-media.c @@ -167,12 +167,9 @@ get_stream_ip_and_ports(GSList *candidates, struct sdpcandidate *candidate = candidates->data; if (type == SIPE_CANDIDATE_TYPE_ANY || candidate->type == type) { - if (!(*ip || - is_empty(candidate->ip) || - /* reject IPv6 addresses */ - strchr(candidate->ip, ':'))) { + if (!*ip) { *ip = g_strdup(candidate->ip); - } else if (!(*ip && sipe_strequal(*ip, candidate->ip))) { + } else if (!sipe_strequal(*ip, candidate->ip)) { continue; } -- 2.11.4.GIT