diff --git a/src/solver.c b/src/solver.c index ff3c495..fbb0dec 100644 --- a/src/solver.c +++ b/src/solver.c @@ -976,7 +976,7 @@ int apk_solver_solve(struct apk_database *db, if (cmpscore(&ss->score, &ss->best_score) < 0) record_solution(ss); - if (cmpscore(&zero_score, &ss->score) <= 0) { + if (cmpscore(&zero_score, &ss->score) >= 0) { /* found solution - it is optimal because we permutate * each preferred local option first, and permutations * happen in topologally sorted order. */