[sr-dev] Question about cdp development

Alfonso Pinto alfonso.pinto at gmail.com
Tue Jan 16 11:57:25 CET 2018


Hi all,

I've to develop a module that uses cdp to contact an HSS. To understand how
to use cdp API I'm looking into other modules that already use it. Of
course, I read also the module documentation.

Looking into ims-registrar-scscf  I found something that triggers my
curiosity. My question is about this
https://github.com/kamailio/kamailio/blob/master/src/modules/ims_registrar_scscf/ims_registrar_scscf_mod.c#L571-L576

The effect of that part is that the callback is going to be added only
once. In that case, why bother with the lock and the shared variable when
the initialisation could be done in mod_init()?

If someone can answer it I would be really grateful.

Cheers,
Alfonso.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20180116/698a5acb/attachment.html>


More information about the sr-dev mailing list