Hi,


i'm investigating a possible memory leak in registrar module, namely in xavp_rcd_helper function.

noticed an increase in shared memory allocated by core, removing the modparam("registrar", "xavp_rcd", "ulrcd") seems to fix this.


[root@dev-01 kamailio]# kamcmd mod.stats core shm
Module: core
{
xavp_new_value(94): 35704
    .....
}

[root@dev-01 kamailio]# kamcmd mod.stats core shm
Module: core
{
xavp_new_value(94): 164064
     ....
}

only one client registering every 60 sec.

not sure if it keeps accumulating values in the xavp or if its leaking.


however, a doubt came across. the lookup function is supposed to fill the xavp if configured, but the value seems to be related to the current process and afaik xavp are allocated in shared memory making it available to all processes. now, if two requests arrive at the same time and both do a lookup on the registrar, the xavp will potentially have the wrong value for one of the requests.


what am i missing here ?


Thanks