[sr-dev] git:5.1:e8b2bf9d: Merge pull request #1572 from christoph-v/bugfix_prm18_0001045_contact_remove_5.1

GitHub noreply at github.com
Fri Jun 22 10:28:42 CEST 2018


Module: kamailio
Branch: 5.1
Commit: e8b2bf9deedfd83d38996d8c5c37761e0e5dcde2
URL: https://github.com/kamailio/kamailio/commit/e8b2bf9deedfd83d38996d8c5c37761e0e5dcde2

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: GitHub <noreply at github.com>
Date: 2018-06-22T10:28:36+02:00

Merge pull request #1572 from christoph-v/bugfix_prm18_0001045_contact_remove_5.1

ims_usrloc_scscf:bugfix erraneous unlinking of deleted contact

---

Modified: src/modules/ims_usrloc_scscf/impurecord.c

---

Diff:  https://github.com/kamailio/kamailio/commit/e8b2bf9deedfd83d38996d8c5c37761e0e5dcde2.diff
Patch: https://github.com/kamailio/kamailio/commit/e8b2bf9deedfd83d38996d8c5c37761e0e5dcde2.patch

---

diff --git a/src/modules/ims_usrloc_scscf/impurecord.c b/src/modules/ims_usrloc_scscf/impurecord.c
index 6510d85aa1..20c8a64154 100644
--- a/src/modules/ims_usrloc_scscf/impurecord.c
+++ b/src/modules/ims_usrloc_scscf/impurecord.c
@@ -1102,10 +1102,11 @@ int remove_impucontact_from_list(impurecord_t* impu, impu_contact_t *impucontact
 	} else if (contact == impu->linked_contacts.tail->contact) {
 		LM_DBG("deleting tail\n");
 		impu->linked_contacts.tail = impu->linked_contacts.tail->prev;
+                impu->linked_contacts.tail->next = 0;
 	} else {
 		LM_DBG("deleting mid list\n");
 		impucontact->prev->next = impucontact->next;
-		impucontact->prev = impucontact->next->prev;
+		impucontact->next->prev = impucontact->prev;
 	}
 	
 	impu->linked_contacts.numcontacts--;




More information about the sr-dev mailing list