From 74c30556fc446885d853d64728e3dccc9a230753 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Thu, 13 Nov 2014 11:39:20 +0100 Subject: [PATCH] xbps_transaction_prepare: check for unresolved shlibs a bit early. It's just better if we check for unresolved shlibs earlier because the transaction array will be smaller if there are replaced packages. --- lib/transaction_dictionary.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/transaction_dictionary.c b/lib/transaction_dictionary.c index 169cb652..fa05fb86 100644 --- a/lib/transaction_dictionary.c +++ b/lib/transaction_dictionary.c @@ -315,6 +315,12 @@ xbps_transaction_prepare(struct xbps_handle *xhp) array = xbps_dictionary_get(xhp->transd, "conflicts"); if (xbps_array_count(array)) return EAGAIN; + /* + * Check for unresolved shared libraries. + */ + if (xbps_transaction_shlibs(xhp, pkgs, + xbps_dictionary_get(xhp->transd, "missing_shlibs"))) + return ENOEXEC; /* * Check for packages to be replaced. */ @@ -323,12 +329,6 @@ xbps_transaction_prepare(struct xbps_handle *xhp) xhp->transd = NULL; return rv; } - /* - * Check for unresolved shared libraries. - */ - if (xbps_transaction_shlibs(xhp, pkgs, xbps_dictionary_get(xhp->transd, "missing_shlibs"))) - return ENOEXEC; - /* * Add transaction stats for total download/installed size, * number of packages to be installed, updated, configured