Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
liblinphone
Commits
df347a97
Commit
df347a97
authored
Jul 26, 2012
by
Ghislain MARY
Browse files
Handle case where ICE is activated and the configured STUN server do not reply.
parent
3cca370e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
6 deletions
+14
-6
coreapi/misc.c
coreapi/misc.c
+13
-5
coreapi/sal_eXosip2_sdp.c
coreapi/sal_eXosip2_sdp.c
+1
-1
No files found.
coreapi/misc.c
View file @
df347a97
...
...
@@ -692,17 +692,25 @@ void linphone_core_gather_ice_candidates(LinphoneCore *lc, LinphoneCall *call)
}
while
(
!
((
audio_gatherings
[
0
].
response
==
TRUE
)
&&
(
audio_gatherings
[
1
].
response
==
TRUE
)
&&
(
!
call
->
params
.
has_video
||
((
video_gatherings
[
0
].
response
==
TRUE
)
&&
(
video_gatherings
[
1
].
response
==
TRUE
)))));
ice_session_compute_candidates_foundations
(
ice_session
);
ice_session_eliminate_redundant_candidates
(
ice_session
);
ice_session_choose_default_candidates
(
ice_session
);
if
((
audio_gatherings
[
0
].
response
==
FALSE
)
||
(
audio_gatherings
[
1
].
response
==
FALSE
)
||
(
call
->
params
.
has_video
&&
((
video_gatherings
[
0
].
response
==
FALSE
)
||
(
video_gatherings
[
1
].
response
==
FALSE
))))
{
/* Failed some STUN checks, deactivate ICE. */
ice_session_destroy
(
ice_session
);
ice_session
=
NULL
;
sal_op_set_ice_session
(
call
->
op
,
ice_session
);
}
else
{
ice_session_compute_candidates_foundations
(
ice_session
);
ice_session_eliminate_redundant_candidates
(
ice_session
);
ice_session_choose_default_candidates
(
ice_session
);
}
close_socket
(
audio_gatherings
[
0
].
sock
);
close_socket
(
audio_gatherings
[
1
].
sock
);
ice_dump_candidates
(
audio_check_list
);
if
(
ice_session
!=
NULL
)
ice_dump_candidates
(
audio_check_list
);
if
(
call
->
params
.
has_video
&&
(
video_check_list
!=
NULL
))
{
if
(
video_gatherings
[
0
].
sock
!=
-
1
)
close_socket
(
video_gatherings
[
0
].
sock
);
if
(
video_gatherings
[
1
].
sock
!=
-
1
)
close_socket
(
video_gatherings
[
1
].
sock
);
ice_dump_candidates
(
video_check_list
);
if
(
ice_session
!=
NULL
)
ice_dump_candidates
(
video_check_list
);
}
}
...
...
coreapi/sal_eXosip2_sdp.c
View file @
df347a97
...
...
@@ -373,7 +373,7 @@ static void add_line(sdp_message_t *msg, int lineno, const SalStreamDescription
}
/*only add a c= line within the stream description if address are differents*/
if
(
strcmp
(
rtp_addr
,
sdp_message_c_addr_get
(
msg
,
-
1
,
0
))
!=
0
){
if
(
rtp_addr
[
0
]
!=
'\0'
&&
strcmp
(
rtp_addr
,
sdp_message_c_addr_get
(
msg
,
-
1
,
0
))
!=
0
){
bool_t
inet6
;
if
(
strchr
(
rtp_addr
,
':'
)
!=
NULL
){
inet6
=
TRUE
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment