Skip to content

Commit

Permalink
Merge beb910e into 91ff81c
Browse files Browse the repository at this point in the history
  • Loading branch information
PengZheng committed Sep 19, 2023
2 parents 91ff81c + beb910e commit 0c2c973
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions libs/framework/src/dm_dependency_manager_impl.c
Original file line number Diff line number Diff line change
Expand Up @@ -260,10 +260,6 @@ celix_array_list_t * celix_dependencyManager_createInfos(celix_dependency_manage
static void celix_dm_allComponentsActiveCallback(void *handle, const celix_bundle_t *bnd) {
bool *allActivePtr = handle;

if (celix_bundle_getState(bnd) != CELIX_BUNDLE_STATE_ACTIVE) {
return;
}

celix_bundle_context_t *context = NULL;
bundle_getContext((celix_bundle_t*)bnd, &context);
celix_dependency_manager_t *mng = celix_bundleContext_getDependencyManager(context);
Expand All @@ -274,9 +270,10 @@ static void celix_dm_allComponentsActiveCallback(void *handle, const celix_bundl
}

bool celix_dependencyManager_allComponentsActive(celix_dependency_manager_t *manager) {
bool allActive = true;
celix_bundleContext_useBundles(manager->ctx, &allActive, celix_dm_allComponentsActiveCallback);
return allActive;
bool allActive = true;
celix_framework_t* fw = celix_bundleContext_getFramework(manager->ctx);
celix_framework_useActiveBundles(fw, true, &allActive, celix_dm_allComponentsActiveCallback);
return allActive;
}

size_t celix_dependencyManager_nrOfComponents(celix_dependency_manager_t *mng) {
Expand Down

0 comments on commit 0c2c973

Please sign in to comment.