Commit 49ae87db authored by Ghislain MARY's avatar Ghislain MARY
Browse files

Fix crash in call_ack_being_sent callback when an automatic wrapper is being used.

parent f00a5b0c
......@@ -480,6 +480,8 @@ void SalCallOp::processResponseCb (void *userCtx, const belle_sip_response_event
lError() << "This call has been already terminated";
// Ref the ack request so that it is not destroyed when the call_ack_being_sent callbacks is called
if (op->mSdpAnswer) {
setSdp(BELLE_SIP_MESSAGE(ack), op->mSdpAnswer);
......@@ -489,6 +491,7 @@ void SalCallOp::processResponseCb (void *userCtx, const belle_sip_response_event
op->mRoot->mCallbacks.call_accepted(op); // INVITE
op->mRoot->mCallbacks.call_ack_being_sent(op, reinterpret_cast<SalCustomHeader *>(ack));
belle_sip_dialog_send_ack(op->mDialog, ack);
op->mState = State::Active;
} else if (code >= 300) {
op->setError(response, false);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment