aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2007-03-19 13:44:18 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2007-03-19 13:44:18 +0000
commitde8a6a01d84ebb09a333104bf0fd5f6e251d9eb7 (patch)
tree00f6cccfc900829cc4113d8f40b1888c03a1102e
parent41e1dc3f8bfea676319f3a69e8556dba2a3a279c (diff)
downloadbusybox-w32-de8a6a01d84ebb09a333104bf0fd5f6e251d9eb7.tar.gz
busybox-w32-de8a6a01d84ebb09a333104bf0fd5f6e251d9eb7.tar.bz2
busybox-w32-de8a6a01d84ebb09a333104bf0fd5f6e251d9eb7.zip
Kim B. Heino writes:
When installing a new package with dpkg dependencies are checked correctly. But when I try to update an existing package, the dependencies are checked against the old package, not against new package. Thus the new package can break dependencies.
-rw-r--r--archival/dpkg.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/archival/dpkg.c b/archival/dpkg.c
index 9f7818ccf..ebdf6c68a 100644
--- a/archival/dpkg.c
+++ b/archival/dpkg.c
@@ -643,11 +643,9 @@ static unsigned fill_package_struct(char *control_buffer)
643 return -1; 643 return -1;
644 } 644 }
645 num = search_package_hashtable(new_node->name, new_node->version, VER_EQUAL); 645 num = search_package_hashtable(new_node->name, new_node->version, VER_EQUAL);
646 if (package_hashtable[num] == NULL) { 646 if (package_hashtable[num] != NULL)
647 package_hashtable[num] = new_node; 647 free_package(package_hashtable[num]);
648 } else { 648 package_hashtable[num] = new_node;
649 free_package(new_node);
650 }
651 return num; 649 return num;
652} 650}
653 651