From 0385812a5a043165ca71bdc9be7d5b3c95259a20 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sun, 6 Jul 2014 09:32:06 +0200 Subject: [PATCH] transaction_sort: if curdep == curpkg don't do any sorting, it's sorted already. --- lib/transaction_sortdeps.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/transaction_sortdeps.c b/lib/transaction_sortdeps.c index 05652afa..a822171f 100644 --- a/lib/transaction_sortdeps.c +++ b/lib/transaction_sortdeps.c @@ -236,6 +236,11 @@ again: if (pkgdepidx < curpkgidx) { xbps_dbg_printf_append(xhp, "already sorted.\n"); pkgdep_release(lpd); + } else if (pd == pdn) { + /* + * Processing same pkg, just continue. + */ + xbps_dbg_printf_append(xhp, "already sorted.\n"); } else { /* * Remove package dependency from list and move