Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liblinphone
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
10
Issues
10
List
Board
Labels
Milestones
Merge Requests
24
Merge Requests
24
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
External Wiki
External Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
BC
public
liblinphone
Commits
49cffafe
Commit
49cffafe
authored
Oct 05, 2018
by
Benjamin REIS
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add linphone_core_clear_frlend_lists api and use it when reading bodyless config
parent
0c389c34
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
2 deletions
+20
-2
linphonecore.c
coreapi/linphonecore.c
+14
-2
core.h
include/linphone/core.h
+6
-0
No files found.
coreapi/linphonecore.c
View file @
49cffafe
...
...
@@ -1340,6 +1340,9 @@ static void certificates_config_read(LinphoneCore *lc) {
}
static
void
bodyless_config_read
(
LinphoneCore
*
lc
)
{
// Clean previous friend lists
linphone_core_clear_friend_lists
(
lc
);
bctbx_list_t
*
bodyless_lists
=
linphone_config_get_string_list
(
lc
->
config
,
"sip"
,
"bodyless_lists"
,
NULL
);
while
(
bodyless_lists
)
{
char
*
name
=
(
char
*
)
bodyless_lists
->
data
;
...
...
@@ -2773,6 +2776,15 @@ void linphone_core_remove_friend_list(LinphoneCore *lc, LinphoneFriendList *list
lc
->
friends_lists
=
bctbx_list_erase_link
(
lc
->
friends_lists
,
elem
);
}
void
linphone_core_clear_friend_lists
(
LinphoneCore
*
lc
)
{
bctbx_list_t
*
list
=
bctbx_list_copy
(
linphone_core_get_friends_lists
((
const
LinphoneCore
*
)
lc
));
bctbx_list_t
*
copy
=
list
;
for
(;
list
!=
NULL
;
list
=
list
->
next
)
{
linphone_core_remove_friend_list
(
lc
,
(
LinphoneFriendList
*
)
list
->
data
);
}
bctbx_list_free
(
copy
);
}
void
linphone_core_add_friend_list
(
LinphoneCore
*
lc
,
LinphoneFriendList
*
list
)
{
if
(
!
list
->
lc
)
{
list
->
lc
=
lc
;
...
...
include/linphone/core.h
View file @
49cffafe
...
...
@@ -5520,6 +5520,12 @@ LINPHONE_PUBLIC void linphone_core_add_friend_list(LinphoneCore *lc, LinphoneFri
*/
LINPHONE_PUBLIC
void
linphone_core_remove_friend_list
(
LinphoneCore
*
lc
,
LinphoneFriendList
*
list
);
/**
* Removes all friend lists.
* @param[in] lc #LinphoneCore object
*/
LINPHONE_PUBLIC
void
linphone_core_clear_friend_lists
(
LinphoneCore
*
lc
);
/**
* Retrieves the list of #LinphoneFriendList from the core.
* @param[in] lc #LinphoneCore object
...
...
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