Commit e706f63e authored by Timo Teräs's avatar Timo Teräs
Browse files

state: handle properly packages which are installed

Installed package does not need to be checked for availability.
Account for packages missing if they get pruned out due to
installability check.
parent 7ae592a4
......@@ -178,6 +178,8 @@ static void ns_free(apk_name_state_t name)
static inline int apk_state_pkg_available(struct apk_state *state,
struct apk_package *pkg)
if (pkg->ipkg != NULL)
return TRUE;
if (pkg->installed_size == 0)
return TRUE;
if (pkg->filename != NULL)
......@@ -316,6 +318,7 @@ int apk_state_prune_dependency(struct apk_state *state,
if (c->num <= 1) {
state->name[name->id] = ns_from_pkg(NULL);
*apk_name_array_add(&state->missing) = name;
return -1;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment