From 48b5d06445b24ce6f3cf433fabd1ef8fe87a2977 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Thu, 14 Jan 2016 14:38:23 +0100 Subject: [PATCH] add user-agent field in ACKs of accepted INVITE transactions --- coreapi/bellesip_sal/sal_op_call.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/coreapi/bellesip_sal/sal_op_call.c b/coreapi/bellesip_sal/sal_op_call.c index 42e636390..482413d6d 100644 --- a/coreapi/bellesip_sal/sal_op_call.c +++ b/coreapi/bellesip_sal/sal_op_call.c @@ -308,7 +308,7 @@ static void call_process_response(void *op_base, const belle_sip_response_event_ if (code >=200 && code<300) { handle_sdp_from_response(op,response); ack=belle_sip_dialog_create_ack(op->dialog,belle_sip_dialog_get_local_seq_number(op->dialog)); - if (ack==NULL) { + if (ack == NULL) { ms_error("This call has been already terminated."); return ; } @@ -317,6 +317,7 @@ static void call_process_response(void *op_base, const belle_sip_response_event_ belle_sip_object_unref(op->sdp_answer); op->sdp_answer=NULL; } + belle_sip_message_add_header(BELLE_SIP_MESSAGE(ack),BELLE_SIP_HEADER(op->base.root->user_agent)); belle_sip_dialog_send_ack(op->dialog,ack); op->base.root->callbacks.call_accepted(op); /*INVITE*/ op->state=SalOpStateActive;