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

del: fix up previous commit

fixes commit "del: fix --rdepends" to not delete provided names
if not using --rdepends
parent f360cace
No related branches found
No related tags found
No related merge requests found
......@@ -114,13 +114,15 @@ static void delete_pkg(struct apk_package *pkg0, struct apk_dependency *dep0,
struct apk_dependency *d;
apk_deps_del(&ctx->world, pkg0->name);
foreach_array_item(d, pkg0->provides)
apk_deps_del(&ctx->world, d->name);
if (ctx->recursive_delete)
if (ctx->recursive_delete) {
foreach_array_item(d, pkg0->provides)
apk_deps_del(&ctx->world, d->name);
apk_pkg_foreach_reverse_dependency(
pkg0, ctx->genid | APK_FOREACH_INSTALLED | APK_DEP_SATISFIES,
delete_pkg, pctx);
}
}
static int delete_name(struct apk_database *db, const char *match,
......
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