fix crash in case of transport change when call is on error

This commit is contained in:
Jehan Monnier 2015-02-19 17:13:35 +01:00
parent cd73647339
commit 587299ce03

View file

@ -217,7 +217,8 @@ static void call_process_response(void *op_base, const belle_sip_response_event_
dialog_state=dialog ? belle_sip_dialog_get_state(dialog) : BELLE_SIP_DIALOG_NULL;
method=belle_sip_request_get_method(req);
ms_message("Op [%p] receiving call response [%i], dialog is [%p] in state [%s]",op,code,dialog,belle_sip_dialog_state_to_string(dialog_state));
/*to make sure no cb will destroy op*/
sal_op_ref(op);
switch(dialog_state) {
case BELLE_SIP_DIALOG_NULL:
case BELLE_SIP_DIALOG_EARLY: {
@ -316,6 +317,7 @@ static void call_process_response(void *op_base, const belle_sip_response_event_
}
break;
}
sal_op_unref(op);
}
static void call_process_timeout(void *user_ctx, const belle_sip_timeout_event_t *event) {