upgrade: handle solver failure gracefully
It is internal bug, but don't segfault on it. Fixes #1576.cute-signatures
parent
4d95266e4d
commit
4c08eca3bb
|
@ -54,7 +54,7 @@ int apk_do_self_upgrade(struct apk_database *db, unsigned short solver_flags)
|
|||
|
||||
r = apk_solver_solve(db, 0, db->world, &solution, &changeset);
|
||||
if (r != 0) {
|
||||
if (apk_flags & APK_FORCE)
|
||||
if ((r > 0) && (apk_flags & APK_FORCE))
|
||||
r = 0;
|
||||
else
|
||||
apk_solver_print_errors(db, solution, db->world, r);
|
||||
|
|
Loading…
Reference in New Issue