@NGSegovia commented on this pull request.
+ lock_get(target->lock);
+ free_destination(target); // Lock is released and freed in this free function
if(!head){
LM_DBG("There isn't any head so maybe it is first \r\n");
ka_destinations_list->first = target->next;
- free_destination(target);
- ka_unlock_destination_list();
- return 1;
+ } else {
+ head->next = target->next;
}
- head->next = target->next;
- free_destination(target);
ka_unlock_destination_list();
Opps, thanks for the catch @linuxmaniac
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2474#discussion_r486425511