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
3f1d66d1
Commit
3f1d66d1
authored
Jan 06, 2016
by
François Grisez
Browse files
Fix removing one participant tester
parent
fe6d7528
Changes
2
Hide whitespace changes
Inline
Side-by-side
tester/multi_call_tester.c
View file @
3f1d66d1
...
...
@@ -653,7 +653,7 @@ static void eject_from_3_participants_conference(LinphoneCoreManager *marie, Lin
BC_ASSERT_TRUE
(
wait_for_list
(
lcs
,
&
laure
->
stat
.
number_of_LinphoneCallEnd
,
1
,
10000
));
}
else
{
linphone_core_terminate_conference
(
marie
->
lc
);
BC_ASSERT_TRUE
(
wait_for_list
(
lcs
,
&
laure
->
stat
.
number_of_LinphoneCallEnd
,
initial_laure_stat
.
number_of_LinphoneCallEnd
+
1
,
3000
));
BC_ASSERT_TRUE
(
wait_for_list
(
lcs
,
&
laure
->
stat
.
number_of_LinphoneCallEnd
,
initial_laure_stat
.
number_of_LinphoneCallEnd
+
2
,
3000
));
BC_ASSERT_TRUE
(
wait_for_list
(
lcs
,
&
marie
->
stat
.
number_of_LinphoneCallEnd
,
initial_marie_stat
.
number_of_LinphoneCallEnd
+
3
,
3000
));
}
...
...
@@ -832,7 +832,7 @@ test_t multi_call_tests[] = {
{
"Unattended call transfer with error"
,
unattended_call_transfer_with_error
},
{
"Call transfer existing call outgoing call"
,
call_transfer_existing_call_outgoing_call
},
{
"Simple remote conference"
,
simple_remote_conference
},
{
"Eject from 3 participants remote conference"
,
eject_from_3_participants_remote_conference
}
{
"Eject from 3 participants
in
remote conference"
,
eject_from_3_participants_remote_conference
}
};
test_suite_t
multi_call_test_suite
=
{
"Multi call"
,
NULL
,
NULL
,
liblinphone_tester_before_each
,
liblinphone_tester_after_each
,
...
...
tester/tester.c
View file @
3f1d66d1
...
...
@@ -700,12 +700,31 @@ void linphone_conference_server_call_state_changed(LinphoneCore *lc, LinphoneCal
}
}
void
linphone_conference_server_refer_received
(
LinphoneCore
*
core
,
const
char
*
refer_to
)
{
char
method
[
20
];
LinphoneAddress
*
refer_to_addr
=
linphone_address_new
(
refer_to
);
char
*
uri
;
LinphoneCall
*
call
;
if
(
refer_to_addr
==
NULL
)
return
;
strncpy
(
method
,
linphone_address_get_method_param
(
refer_to_addr
),
sizeof
(
method
));
if
(
strcmp
(
method
,
"BYE"
)
==
0
)
{
linphone_address_clean
(
refer_to_addr
);
uri
=
linphone_address_as_string_uri_only
(
refer_to_addr
);
call
=
linphone_core_find_call_from_uri
(
core
,
uri
);
if
(
call
)
linphone_core_terminate_call
(
core
,
call
);
ms_free
(
uri
);
}
linphone_address_destroy
(
refer_to_addr
);
}
LinphoneConferenceServer
*
linphone_conference_server_new
(
const
char
*
rc_file
)
{
LinphoneConferenceServer
*
conf_srv
=
(
LinphoneConferenceServer
*
)
ms_new0
(
LinphoneConferenceServer
,
1
);
LinphoneCoreManager
*
lm
=
(
LinphoneCoreManager
*
)
conf_srv
;
conf_srv
->
vtable
=
linphone_core_v_table_new
();
conf_srv
->
vtable
->
call_state_changed
=
linphone_conference_server_call_state_changed
;
conf_srv
->
vtable
->
refer_received
=
linphone_conference_server_refer_received
;
conf_srv
->
vtable
->
user_data
=
conf_srv
;
linphone_core_manager_init
(
lm
,
rc_file
);
linphone_core_add_listener
(
lm
->
lc
,
conf_srv
->
vtable
);
...
...
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