Skip to content

Commit

Permalink
Remove unnecessary test.
Browse files Browse the repository at this point in the history
"res" cannot be null at that point
  • Loading branch information
bogdan-iancu committed Jul 22, 2016
1 parent bfe55b9 commit 0b60681
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions modules/drouting/drouting.c
Expand Up @@ -1895,11 +1895,9 @@ static inline int get_group_id(struct sip_uri *uri, struct head_db *
}

if (RES_ROW_N(res) == 0) {
if (dr_default_grp!=-1)
{
if (res)
(current_partition->db_funcs).free_result(*(current_partition->db_con), res);

if (dr_default_grp!=-1) {
(current_partition->db_funcs).free_result
(*(current_partition->db_con), res);
return dr_default_grp;
}
LM_ERR("no group for user "
Expand Down

0 comments on commit 0b60681

Please sign in to comment.