- prevent from resetting sock_flag to -1 when reg_xavp_cfg is set You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/470
-- Commit Summary --
* registrar: do make use of reg_xavp_cfg
-- File Changes --
M modules/registrar/reg_mod.c (8)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/470.patch https://github.com/kamailio/kamailio/pull/470.diff
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/470
Thanks!
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/470#issuecomment-170011308
Merged #470.
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/470#event-509434087
Hi @jayesh1017,
Thanks for pointing out. From the commit I shouldn't reset the `reg_xavp_cfg` since there are other functions like `registered()` would use it. Here's the diff and I will create a new pull request for this soon.
```diff --- a/modules/registrar/reg_mod.c +++ b/modules/registrar/reg_mod.c @@ -365,7 +365,6 @@ static int mod_init(void) } else if (reg_xavp_cfg.s) { if (reg_xavp_cfg.len == 0 || sock_flag == -1) { LM_WARN("empty reg_xavp_cfg or sock_flag no set -> resetting\n"); - reg_xavp_cfg.len = 0; sock_flag = -1; } } else if (sock_flag!=-1) { ```
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/470#issuecomment-171556933