}
if (body_out)
*body_out = body;
+ if (op == OP_DELETE) {
+ /* Delete the key<->value from the hashtable */
+ if (!rtpengine_hash_table_remove(&callid)) {
If you can be bothered with 2, then go for it, but I think it would take a lot of work and
fine-tuning to make it work just right. The proxies already do all the tag and branch
handling so I see no need to duplicate it here.
Setting the expiry to the near future on "delete" would help to keep the hash
table small if it was indeed the final BYE, but it would also require resetting the expiry
to now+timeout on every operation, i.e. not only when the key is created but on a lookup
as well.
Another option would be to extend the control protocol and have the RTP proxy tell the
module whether this call is finished now or if it should be kept alive.
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/390/files#r44656355