Module: kamailio Branch: master Commit: 19c69e8094570a60eaf056ecac57ed26fce9d3a7 URL: https://github.com/kamailio/kamailio/commit/19c69e8094570a60eaf056ecac57ed26...
Author: frederic frederic.gaisnon@mmtt.fr Committer: frederic frederic.gaisnon@mmtt.fr Date: 2021-02-16T11:10:11+01:00
htable: ht_dmq_replicate_action was always called on ht_rm_items even if dmq was not activated
---
Modified: src/modules/htable/htable.c
---
Diff: https://github.com/kamailio/kamailio/commit/19c69e8094570a60eaf056ecac57ed26... Patch: https://github.com/kamailio/kamailio/commit/19c69e8094570a60eaf056ecac57ed26...
---
diff --git a/src/modules/htable/htable.c b/src/modules/htable/htable.c index d05cf5227d..1bb36657de 100644 --- a/src/modules/htable/htable.c +++ b/src/modules/htable/htable.c @@ -484,7 +484,7 @@ static int ht_rm_items(sip_msg_t* msg, str* hname, str* op, str *val, case 2: if(strncmp(op->s, "re", 2)==0) { isval.s = *val; - if (ht_dmq_replicate_action(HT_DMQ_RM_CELL_RE, &ht->name, NULL, + if ((ht->dmqreplicate > 0) && ht_dmq_replicate_action(HT_DMQ_RM_CELL_RE, &ht->name, NULL, AVP_VAL_STR, &isval, mkey)!=0) { LM_ERR("dmq relication failed (op %d)\n", mkey); } @@ -494,7 +494,7 @@ static int ht_rm_items(sip_msg_t* msg, str* hname, str* op, str *val, return 1; } else if(strncmp(op->s, "sw", 2)==0) { isval.s = *val; - if (ht_dmq_replicate_action(HT_DMQ_RM_CELL_SW, &ht->name, NULL, + if ((ht->dmqreplicate > 0) &&ht_dmq_replicate_action(HT_DMQ_RM_CELL_SW, &ht->name, NULL, AVP_VAL_STR, &isval, mkey)!=0) { LM_ERR("dmq relication failed (op %d)\n", mkey); }