Skip to content

Commit

Permalink
siptrace: exported sip_trace_msg() to kemi
Browse files Browse the repository at this point in the history
  • Loading branch information
miconda committed May 9, 2023
1 parent d42497e commit c75e4a0
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions src/modules/siptrace/siptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -1225,6 +1225,18 @@ static int w_sip_trace_msg(sip_msg_t *msg, char *vmsg, char *saddr, char *taddr,
return 1;
}

/**
*
*/
static int ki_sip_trace_msg(sip_msg_t *msg, str *vmsg, str *saddr, str *taddr,
str *duri, str *corrid)
{
trace_send_hep_duplicate(vmsg, saddr, taddr, (duri && duri->len>0)?&duri:NULL,
(corrid && corrid->len>0)?corrid:NULL);

return 1;
}

/**
* link call-id, method, from-tag and to-tag
*/
Expand Down Expand Up @@ -2600,6 +2612,11 @@ static sr_kemi_t sr_kemi_siptrace_exports[] = {
{ SR_KEMIP_STR, SR_KEMIP_NONE, SR_KEMIP_NONE,
SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
},
{ str_init("siptrace"), str_init("sip_trace_msg"),
SR_KEMIP_INT, ki_sip_trace_msg,
{ SR_KEMIP_STR, SR_KEMIP_STR, SR_KEMIP_STR,
SR_KEMIP_STR, SR_KEMIP_STR, SR_KEMIP_NONE }
},

{ {0, 0}, {0, 0}, 0, NULL, { 0, 0, 0, 0, 0, 0 } }
};
Expand Down

0 comments on commit c75e4a0

Please sign in to comment.