summaryrefslogtreecommitdiff
path: root/src/del.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/del.c')
-rw-r--r--src/del.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/del.c b/src/del.c
index 03b720e..c88bc81 100644
--- a/src/del.c
+++ b/src/del.c
@@ -56,13 +56,12 @@ static int del_main(void *ctx, struct apk_database *db, int argc, char **argv)
.result_mask = APK_DEPMASK_CONFLICT,
};
- r = apk_state_lock_dependency(state, &dep);
- if (r != 0) {
- apk_error("Unable to remove '%s'", name->name);
- goto err;
- }
+ r |= apk_state_lock_dependency(state, &dep);
}
- r = apk_state_commit(state, db);
+ if (r == 0)
+ r = apk_state_commit(state, db);
+ else
+ apk_state_print_errors(state);
err:
if (state != NULL)
apk_state_unref(state);