I think build_rtpp_socks() does not leak pkg memory because it uses pkg_**re**alloc;
comparing the old rtpp_socks with the new rtpp_socks, they point to the same address.
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/429#issuecomment-173851436