Skip to content

Commit

Permalink
json: properly check pv_parse_spec() return
Browse files Browse the repository at this point in the history
Fixes Coverity 40485

(cherry picked from commit 7bc6bd6)
  • Loading branch information
razvancrainea committed Nov 11, 2016
1 parent c9a9daa commit 05e03da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/json/json.c
Expand Up @@ -822,7 +822,7 @@ int get_value(int state, json_name * id, char *start, char * cur)

if( *i == '$' )
{
if( pv_parse_spec(&in, &node->var) < 0 )
if(!pv_parse_spec(&in, &node->var))
{
LM_ERR("Unable to parse variable ");
return -1;
Expand Down

0 comments on commit 05e03da

Please sign in to comment.