Module: kamailio Branch: master Commit: ace37c7a60e5d931216339c179de6e91615dac7e URL: https://github.com/kamailio/kamailio/commit/ace37c7a60e5d931216339c179de6e91...
Author: Jon Bergli Heier jon.bergli.heier@zisson.no Committer: Jon Bergli Heier jon.bergli.heier@zisson.no Date: 2015-05-07T11:08:08+02:00
htable: Add missing ht_slot_unlock in ht_cell_value_add
---
Modified: modules/htable/ht_api.c
---
Diff: https://github.com/kamailio/kamailio/commit/ace37c7a60e5d931216339c179de6e91... Patch: https://github.com/kamailio/kamailio/commit/ace37c7a60e5d931216339c179de6e91...
---
diff --git a/modules/htable/ht_api.c b/modules/htable/ht_api.c index 690f9c7..fb0b117 100644 --- a/modules/htable/ht_api.c +++ b/modules/htable/ht_api.c @@ -672,7 +672,10 @@ ht_cell_t* ht_cell_value_add(ht_t *ht, str *name, int val, int mode, } /* add val if htable has an integer init value */ if(ht->flags!=PV_VAL_INT) + { + if(mode) ht_slot_unlock(ht, idx); return NULL; + } isval.n = ht->initval.n + val; it = ht_cell_new(name, 0, &isval, hid); if(it == NULL)