Skip to content

Commit

Permalink
core: parse_ppi_pai - free header parameters for PAI and PPI
Browse files Browse the repository at this point in the history
- they are not considere in the compacted p_id_body_t and not freed
- specs don't mention headers parameters for PAI and PPI, but could come
  as UA extensions

(cherry picked from commit c1b4d44)
  • Loading branch information
miconda committed Jan 15, 2015
1 parent b7657fd commit 38d6c0b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions parser/parse_ppi_pai.c
Expand Up @@ -62,6 +62,8 @@ int parse_pai_ppi_body(char *buf, int len, p_id_body_t **body)
LM_ERR("Error parsing PAI/PPI body %u '%.*s'\n", num_uri, len, buf);
return -1;
}
/* should be no header params, but in case there are, free them */
free_to_params(&uri_b[num_uri]);
num_uri++;
while ((*tmp == ',') && (num_uri < NUM_PAI_BODIES))
{
Expand All @@ -72,6 +74,8 @@ int parse_pai_ppi_body(char *buf, int len, p_id_body_t **body)
LM_ERR("Error parsing PAI/PPI body %u '%.*s'\n", num_uri, len, buf);
return -1;
}
/* should be no header params, but in case there are, free them */
free_to_params(&uri_b[num_uri]);
num_uri++;
}
if (num_uri >= NUM_PAI_BODIES)
Expand Down

0 comments on commit 38d6c0b

Please sign in to comment.