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
f9e07825
Commit
f9e07825
authored
Sep 16, 2013
by
Simon Morlat
Browse files
enable generic publish not to be refreshed automatically
parent
a1ec7d69
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
12 additions
and
1 deletion
+12
-1
coreapi/bellesip_sal/sal_impl.h
coreapi/bellesip_sal/sal_impl.h
+1
-0
coreapi/bellesip_sal/sal_op_events.c
coreapi/bellesip_sal/sal_op_events.c
+1
-0
coreapi/bellesip_sal/sal_op_impl.c
coreapi/bellesip_sal/sal_op_impl.c
+6
-0
coreapi/event.c
coreapi/event.c
+1
-0
coreapi/help/Doxyfile.in
coreapi/help/Doxyfile.in
+1
-1
include/sal/sal.h
include/sal/sal.h
+2
-0
No files found.
coreapi/bellesip_sal/sal_impl.h
View file @
f9e07825
...
...
@@ -96,6 +96,7 @@ struct SalOp{
bool_t
auto_answer_asked
;
bool_t
sdp_offering
;
bool_t
call_released
;
bool_t
manual_refresher
;
};
...
...
coreapi/bellesip_sal/sal_op_events.c
View file @
f9e07825
...
...
@@ -84,6 +84,7 @@ static void subscribe_response_event(void *op_base, const belle_sip_response_eve
}
if
(
expires
>
0
){
op
->
refresher
=
belle_sip_client_transaction_create_refresher
(
client_transaction
);
if
(
op
->
refresher
)
belle_sip_refresher_enable_manual_mode
(
op
->
refresher
,
op
->
manual_refresher
);
}
if
(
sss
==
SalSubscribeNone
)
sss
=
SalSubscribeActive
;
/*without Subscription-state header, consider subscription is accepted.*/
op
->
base
.
root
->
callbacks
.
subscribe_response
(
op
,
sss
,
SalErrorNone
,
SalReasonUnknown
);
...
...
coreapi/bellesip_sal/sal_op_impl.c
View file @
f9e07825
...
...
@@ -25,6 +25,7 @@ SalOp * sal_op_new(Sal *sal){
__sal_op_init
(
op
,
sal
);
op
->
type
=
SalOpUnknown
;
op
->
privacy
=
SalPrivacyNone
;
op
->
manual_refresher
=
FALSE
;
/*tells that requests with expiry (SUBSCRIBE, PUBLISH) will be automatically refreshed*/
sal_op_ref
(
op
);
return
op
;
}
...
...
@@ -478,6 +479,7 @@ int sal_op_send_and_create_refresher(SalOp* op,belle_sip_request_t* req, int exp
if
((
op
->
refresher
=
belle_sip_client_transaction_create_refresher
(
op
->
pending_client_trans
)))
{
belle_sip_refresher_set_listener
(
op
->
refresher
,
listener
,
op
);
belle_sip_refresher_set_retry_after
(
op
->
refresher
,
op
->
base
.
root
->
refresher_retry_after
);
belle_sip_refresher_enable_manual_mode
(
op
->
refresher
,
op
->
manual_refresher
);
return
0
;
}
else
{
return
-
1
;
...
...
@@ -573,3 +575,7 @@ bool_t sal_op_is_secure(const SalOp* op) {
return
from
&&
to
&&
strcasecmp
(
"sips"
,
sal_address_get_scheme
(
from
))
==
0
&&
strcasecmp
(
"sips"
,
sal_address_get_scheme
(
to
))
==
0
;
}
void
sal_op_set_manual_refresher_mode
(
SalOp
*
op
,
bool_t
enabled
){
op
->
manual_refresher
=
enabled
;
}
coreapi/event.c
View file @
f9e07825
...
...
@@ -157,6 +157,7 @@ LinphoneEvent *linphone_core_publish(LinphoneCore *lc, const LinphoneAddress *re
SalBody
salbody
;
LinphoneEvent
*
lev
=
linphone_event_new
(
lc
,
LinphoneSubscriptionInvalidDir
,
event
);
linphone_configure_op
(
lc
,
lev
->
op
,
resource
,
NULL
,
lp_config_get_int
(
lc
->
config
,
"sip"
,
"publish_msg_with_contact"
,
0
));
sal_op_set_manual_refresher_mode
(
lev
->
op
,
lp_config_get_int
(
lc
->
config
,
"sip"
,
"refresh_generic_publish"
,
1
));
sal_publish
(
lev
->
op
,
NULL
,
NULL
,
event
,
expires
,
sal_body_from_content
(
&
salbody
,
body
));
return
lev
;
}
...
...
coreapi/help/Doxyfile.in
View file @
f9e07825
...
...
@@ -165,7 +165,7 @@ MAN_LINKS = NO
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML =
NO
GENERATE_XML =
YES
XML_OUTPUT = xml
XML_SCHEMA =
XML_DTD =
...
...
include/sal/sal.h
View file @
f9e07825
...
...
@@ -499,6 +499,8 @@ const char* sal_op_get_call_id(const SalOp *op);
const
SalAddress
*
sal_op_get_service_route
(
const
SalOp
*
op
);
void
sal_op_set_service_route
(
SalOp
*
op
,
const
SalAddress
*
service_route
);
void
sal_op_set_manual_refresher_mode
(
SalOp
*
op
,
bool_t
enabled
);
/*Call API*/
int
sal_call_set_local_media_description
(
SalOp
*
h
,
SalMediaDescription
*
desc
);
int
sal_call
(
SalOp
*
h
,
const
char
*
from
,
const
char
*
to
);
...
...
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