Skip to content
Snippets Groups Projects
Commit ba005f2e authored by Timo Teräs's avatar Timo Teräs
Browse files

state: bug fix

parent bf7b8066
No related branches found
No related tags found
No related merge requests found
......@@ -131,7 +131,8 @@ static int add_main(void *ctx, struct apk_database *db, int argc, char **argv)
for (i = 0; (pkgs != NULL) && i < pkgs->num; i++) {
r = apk_state_lock_dependency(state, &pkgs->item[i]);
if (r != 0) {
apk_error("Unable to install '%s'", pkgs->item[i].name->name);
apk_error("Unable to install '%s': %d",
pkgs->item[i].name->name, r);
if (!(apk_flags & APK_FORCE))
goto err;
}
......
......@@ -113,11 +113,10 @@ static struct apk_name_choices *name_choices_new(struct apk_database *db,
& dep->result_mask) {
j++;
} else {
nc->pkgs[i] = nc->pkgs[nc->num - 1];
nc->pkgs[j] = nc->pkgs[nc->num - 1];
nc->num--;
}
}
}
return nc;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment