From 01915e30300962ad06ec77ca8534d7b89268fd58 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Tue, 25 Sep 2012 15:02:57 +0200 Subject: [PATCH] xbps_transaction_update_packages: make packages on hold work (duh!). (cherry picked from commit aa154199a6d7d89bfe040755be289b1d827c5727) --- lib/transaction_ops.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/transaction_ops.c b/lib/transaction_ops.c index aa262796..666bd38e 100644 --- a/lib/transaction_ops.c +++ b/lib/transaction_ops.c @@ -204,7 +204,7 @@ xbps_transaction_update_packages(struct xbps_handle *xhp) { prop_object_t obj; const char *pkgname, *holdpkgname; - bool newpkg_found = false; + bool foundhold = false, newpkg_found = false; int rv = 0; size_t i, x; @@ -219,9 +219,14 @@ xbps_transaction_update_packages(struct xbps_handle *xhp) if (strcmp(pkgname, holdpkgname) == 0) { xbps_dbg_printf(xhp, "[rpool] package %s on hold, " "ignoring updates.\n", pkgname); - continue; + foundhold = true; + break; } } + if (foundhold) { + foundhold = false; + continue; + } rv = transaction_find_pkg(xhp, pkgname, false, true, false, TRANS_UPDATE); if (rv == 0)