Skip to content

Commit

Permalink
sipt: reset the static buffer for returning the number
Browse files Browse the repository at this point in the history
- GH #2030

(cherry picked from commit 2c05297)
  • Loading branch information
miconda authored and henningw committed Aug 9, 2019
1 parent b88e04e commit 24e3272
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/modules/sipt/sipt.c
Expand Up @@ -339,6 +339,7 @@ static int sipt_get_redirection_number(struct sip_msg *msg, pv_param_t *param, p
str body;
body.s = get_body_part(msg, TYPE_APPLICATION,SUBTYPE_ISUP,&body.len);

sb_s_buf[0] = '\0';
if(body.s == NULL)
{
LM_INFO("No ISUP Message Found");
Expand All @@ -350,9 +351,9 @@ static int sipt_get_redirection_number(struct sip_msg *msg, pv_param_t *param, p
LM_DBG("message not an ACM or CPG\n");
return -1;
}

isup_get_redirection_number((unsigned char*)body.s, body.len, sb_s_buf);

if (strlen(sb_s_buf) > 0)
{
pv_get_strzval(msg, param, res, sb_s_buf);
Expand Down

0 comments on commit 24e3272

Please sign in to comment.