Fix rare segfault on package removal
commitfcbae69fe81d080478bbd9809af5696bbbfe9d95
authorAllan McRae <allan@archlinux.org>
Tue, 31 Jan 2012 17:11:47 +0000 (1 03:11 +1000)
committerDan McGee <dan@archlinux.org>
Tue, 31 Jan 2012 17:22:30 +0000 (31 11:22 -0600)
tree1fc1afc5d45baf6d41f06a34b1f3f2dcf46c8f15
parent9d1e8084dfa0a1ebae6c37e3b839289cb905116f
Fix rare segfault on package removal

Very rarely a segfault would occur when removing a number of packages
due to a corrupted list for the local database (FS#27805, FS#28195).
This was caused by the alpm_list_msort function not correctly dealing
with the two new head node's prev values.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
lib/libalpm/alpm_list.c