Module: kamailio
Branch: master
Commit: a0594f0e70dd860a22e94733f965b151ff99e641
URL:
https://github.com/kamailio/kamailio/commit/a0594f0e70dd860a22e94733f965b15…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: GitHub <noreply(a)github.com>
Date: 2018-06-20T08:27:49+02:00
Merge pull request #1562 from christoph-v/bugfix_prm18_0001045_contact_remove
ims_usrloc_scscf: bugfix erraneous unlinking of deleted contact
---
Modified: src/modules/ims_usrloc_scscf/impurecord.c
---
Diff:
https://github.com/kamailio/kamailio/commit/a0594f0e70dd860a22e94733f965b15…
Patch:
https://github.com/kamailio/kamailio/commit/a0594f0e70dd860a22e94733f965b15…
---
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--;