From: Martin Willi Date: Wed, 29 Feb 2012 15:07:16 +0000 (+0100) Subject: Don't depend on a feature that has a dependency to the same feauture during unload X-Git-Tag: 5.0.0~337 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f14bf6345fff3139fde71c3864184746eaf89499;p=thirdparty%2Fstrongswan.git Don't depend on a feature that has a dependency to the same feauture during unload --- diff --git a/src/libstrongswan/plugins/plugin_loader.c b/src/libstrongswan/plugins/plugin_loader.c index 164b68e604..94ef00b2e2 100644 --- a/src/libstrongswan/plugins/plugin_loader.c +++ b/src/libstrongswan/plugins/plugin_loader.c @@ -361,7 +361,8 @@ static bool dependency_required(private_plugin_loader_t *this, count = entry->plugin->get_features(entry->plugin, &features); for (i = 0; i < count; i++) { - if (feature_loaded(this, entry, &features[i])) + if (&features[i] != dep && + feature_loaded(this, entry, &features[i])) { while (++i < count && (features[i].kind == FEATURE_DEPENDS || features[i].kind == FEATURE_SDEPEND))