Skip to content

Commit

Permalink
Fix PKG mem leak
Browse files Browse the repository at this point in the history
  • Loading branch information
vladpaiu committed Mar 18, 2015
1 parent dd81c75 commit f276691
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions modules/drouting/drouting.c
Expand Up @@ -3115,6 +3115,7 @@ static int route2_carrier(struct sip_msg* msg, char* part_carrier,

/* we are done reading -> unref the data */
lock_stop_read( current_partition->ref_lock );
if (ruri_buf) pkg_free(ruri_buf);

return 1;
error:
Expand Down Expand Up @@ -3251,6 +3252,7 @@ static int route2_gw(struct sip_msg* msg, char* ch_part_gw, char* gw_att_pv)
}
}

if (ruri_buf) pkg_free(ruri_buf);
return 1;

error_free:
Expand Down

0 comments on commit f276691

Please sign in to comment.