Hello,

recently I added a new option that can be set for an integer
modparam: PARAM_USE_SHM (i.e., PARAM_INT | PARAM_USE_SHM). The pointer
given in the exports structure has to be the address of a pointer to an
int. The result is that the modparam will allocated an integer in shared
memory and store the provided value there. It makes it possible to change
the value at runtime via the new rpc command: modparam.setn.

An example of use is the keylog_mode parameter from tls module.

This should simplify coding in the future when one needs to add a new int
parameter that can be changed at runtime, without need to code the full set
of allocating shared memory and implementing dedicated rpc commands.

There are several such parameters already (e.g., all these modparams to
enable/disable features like for sipdump), they can be reviewed if they
should be migrated or not, but it is also fine to be kept like they are,
some of they might have custom processing behind the rpc command.

Cheers,
Daniel

-- 
Daniel-Constantin Mierla - https://www.asipto.com
- Kamailio Consultancy And Training Services -
https://twitter.com/miconda - https://www.linkedin.com/in/miconda
_______________________________________________
Kamailio - Development Mailing List -- sr-dev@lists.kamailio.org
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!

Reply via email to