I pushed a patch for it - commit 5937b04 - as I could spot, there was no locking done before the insert, but only unlocking. Would be good if you can test and report the results.
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/issues/440#issuecomment-166310109