Also, it would be simpler to declare a static container for tmp_comment (look at static
char query[QUERY_LEN] in cr_db.c) instead of you taking care of the allocaion each time.
This is possible because add_route actually duplicates the string in tmp_comment.
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/221#issuecomment-117753968