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
belle-sip
Commits
35a71156
Commit
35a71156
authored
May 07, 2013
by
jehan
Browse files
make sure transaction error even in init state are repported
parent
a6f3af18
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/message.c
View file @
35a71156
...
...
@@ -365,7 +365,7 @@ const char* belle_sip_message_get_body(belle_sip_message_t *msg) {
void
belle_sip_message_set_body
(
belle_sip_message_t
*
msg
,
const
char
*
body
,
unsigned
int
size
)
{
if
(
msg
->
body
)
{
belle_sip_free
((
void
*
)
body
);
belle_sip_free
((
void
*
)
msg
->
body
);
}
msg
->
body
=
belle_sip_malloc
(
size
+
1
);
memcpy
(
msg
->
body
,
body
,
size
);
...
...
src/refresher.c
View file @
35a71156
...
...
@@ -79,8 +79,10 @@ static void process_io_error(void *user_ctx, const belle_sip_io_error_event_t *e
if
(
belle_sip_object_is_instance_of
(
BELLE_SIP_OBJECT
(
belle_sip_io_error_event_get_source
(
event
)),
BELLE_SIP_TYPE_ID
(
belle_sip_client_transaction_t
)))
{
client_transaction
=
BELLE_SIP_CLIENT_TRANSACTION
(
belle_sip_io_error_event_get_source
(
event
));
if
(
!
refresher
||
(
refresher
&&
((
refresher
->
state
==
stopped
&&
belle_sip_transaction_get_state
(
BELLE_SIP_TRANSACTION
(
refresher
->
transaction
))
!=
BELLE_SIP_TRANSACTION_TRYING
)
||
client_transaction
!=
refresher
->
transaction
)))
if
(
!
refresher
||
(
refresher
&&
((
refresher
->
state
==
stopped
&&
belle_sip_transaction_get_state
(
BELLE_SIP_TRANSACTION
(
refresher
->
transaction
))
!=
BELLE_SIP_TRANSACTION_TRYING
&&
belle_sip_transaction_get_state
(
BELLE_SIP_TRANSACTION
(
refresher
->
transaction
))
!=
BELLE_SIP_TRANSACTION_INIT
/*to cover dns or certificate error*/
)
||
client_transaction
!=
refresher
->
transaction
)))
return
;
/*not for me or no longuer involved*/
if
(
refresher
->
expires
>
0
)
retry_after
(
refresher
);
...
...
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