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
23
Merge Requests
23
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
9313618c
Commit
9313618c
authored
Sep 05, 2016
by
Gautier Pelloux-Prayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
presence: dont notify uselessly
parent
dce0f4d4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
5 deletions
+2
-5
friendlist.c
coreapi/friendlist.c
+2
-2
vtables.c
coreapi/vtables.c
+0
-3
No files found.
coreapi/friendlist.c
View file @
9313618c
...
...
@@ -320,7 +320,7 @@ static void linphone_friend_list_parse_multipart_related_body(LinphoneFriendList
LinphoneAddress
*
addr
=
(
LinphoneAddress
*
)
bctbx_list_get_data
(
iterator
);
char
*
uri
=
linphone_address_as_string_uri_only
(
addr
);
const
LinphonePresenceModel
*
presence
=
linphone_friend_get_presence_model_for_uri_or_tel
(
lf
,
uri
);
linphone_core_notify_notify_presence_received_for_uri_or_tel
(
list
->
lc
,
lf
,
uri
,
presence
);
if
(
presence
)
linphone_core_notify_notify_presence_received_for_uri_or_tel
(
list
->
lc
,
lf
,
uri
,
presence
);
ms_free
(
uri
);
iterator
=
bctbx_list_next
(
iterator
);
}
...
...
@@ -329,7 +329,7 @@ static void linphone_friend_list_parse_multipart_related_body(LinphoneFriendList
while
(
iterator
)
{
const
char
*
number
=
(
const
char
*
)
bctbx_list_get_data
(
iterator
);
const
LinphonePresenceModel
*
presence
=
linphone_friend_get_presence_model_for_uri_or_tel
(
lf
,
number
);
linphone_core_notify_notify_presence_received_for_uri_or_tel
(
list
->
lc
,
lf
,
number
,
presence
);
if
(
presence
)
linphone_core_notify_notify_presence_received_for_uri_or_tel
(
list
->
lc
,
lf
,
number
,
presence
);
iterator
=
bctbx_list_next
(
iterator
);
}
if
(
numbers
)
bctbx_list_free
(
numbers
);
...
...
coreapi/vtables.c
View file @
9313618c
...
...
@@ -69,13 +69,10 @@ static void cleanup_dead_vtable_refs(LinphoneCore *lc){
#define NOTIFY_IF_EXIST_INTERNAL(function_name, internal_val, ...) \
bctbx_list_t* iterator; \
VTableReference *ref; \
bool_t has_cb = FALSE; \
for (iterator=lc->vtable_refs; iterator!=NULL; iterator=iterator->next)\
if ((ref=(VTableReference*)iterator->data)->valid && (lc->current_vtable=ref->vtable)->function_name && (ref->internal == internal_val)) {\
lc->current_vtable->function_name(__VA_ARGS__);\
has_cb = TRUE;\
}\
if (has_cb) ms_message("Linphone core [%p] notifying [%s]",lc,#function_name)
void
linphone_core_notify_global_state_changed
(
LinphoneCore
*
lc
,
LinphoneGlobalState
gstate
,
const
char
*
message
)
{
NOTIFY_IF_EXIST
(
global_state_changed
,
lc
,
gstate
,
message
);
...
...
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