diff --git a/res/res_pjsip_header_funcs.c b/res/res_pjsip_header_funcs.c index 11ab44c104ac520d7937ed2bf94e11ab6803f0ec..063fbb7616d7a03f22337c18295b17d89fae4777 100644 --- a/res/res_pjsip_header_funcs.c +++ b/res/res_pjsip_header_funcs.c @@ -583,7 +583,8 @@ static void outgoing_request(struct ast_sip_session *session, pjsip_tx_data * td RAII_VAR(struct ast_datastore *, datastore, ast_sip_session_get_datastore(session, header_datastore.type), ao2_cleanup); - if (!datastore || !datastore->data) { + if (!datastore || !datastore->data || + (session->inv_session->state >= PJSIP_INV_STATE_CONFIRMED)) { return; }