alternatives: preserve order while updating pkgs (thanks chris2/duncaen).

This commit is contained in:
Juan RP
2015-11-17 16:32:12 +01:00
parent 28a6f8f9e5
commit 93b50bc4dc
4 changed files with 69 additions and 1 deletions

View File

@ -319,6 +319,9 @@ xbps_remove_pkg(struct xbps_handle *xhp, const char *pkgver, bool update)
goto out;
/* unregister alternatives */
if (update)
xbps_dictionary_set_bool(pkgd, "alternatives-update", true);
if ((rv = xbps_alternatives_unregister(xhp, pkgd)) != 0)
goto out;