Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Reduce the block depth
Baptiste Daroussin committed 9 years ago
commit a7e18f1c8e8bf66081b9c6cf4181f1fb6733bb6d
parent 914db15
1 file changed +16 -15
modified libpkg/pkg_jobs_universe.c
@@ -729,21 +729,22 @@ pkg_jobs_update_universe_item_priority(struct pkg_jobs_universe *universe,
					maxpri, type);
			return;
		}
-
		if (it->pkg->type != PKG_INSTALLED) {
-
			while (pkg_conflicts(it->pkg, &c) == EPKG_OK) {
-
				HASH_FIND_STR(universe->items, c->uid, found);
-
				if (found != NULL) {
-
					LL_FOREACH(found, cur) {
-
						if (cur->pkg->type == PKG_INSTALLED) {
-
							/*
-
							 * Move delete requests to be done before installing
-
							 */
-
							if (cur->priority <= it->priority)
-
								pkg_jobs_update_universe_item_priority(universe, cur,
-
									it->priority + 1, PKG_PRIORITY_UPDATE_CONFLICT);
-
						}
-
					}
-
				}
+
		if (it->pkg->type == PKG_INSTALLED)
+
			continue;
+

+
		while (pkg_conflicts(it->pkg, &c) == EPKG_OK) {
+
			HASH_FIND_STR(universe->items, c->uid, found);
+
			if (found == NULL)
+
				continue;
+
			LL_FOREACH(found, cur) {
+
				if (cur->pkg->type != PKG_INSTALLED)
+
					continue;
+
				/*
+
				 * Move delete requests to be done before installing
+
				 */
+
				if (cur->priority <= it->priority)
+
					pkg_jobs_update_universe_item_priority(universe, cur,
+
					    it->priority + 1, PKG_PRIORITY_UPDATE_CONFLICT);
			}
		}
	}