diff options
| author | Yves-Alexis Perez <corsac@debian.org> | 2013-08-25 15:37:26 +0200 |
|---|---|---|
| committer | Yves-Alexis Perez <corsac@debian.org> | 2013-08-25 15:37:26 +0200 |
| commit | 6b99c8d9cff7b3e8ae8f3204b99e7ea40f791349 (patch) | |
| tree | 009fc492961e13860d2a4bc2de8caf2bbe2975e7 /src/libstrongswan/plugins/unbound/unbound_plugin.c | |
| parent | c83921a2b566aa9d55d8ccc7258f04fca6292ee6 (diff) | |
| download | vyos-strongswan-6b99c8d9cff7b3e8ae8f3204b99e7ea40f791349.tar.gz vyos-strongswan-6b99c8d9cff7b3e8ae8f3204b99e7ea40f791349.zip | |
Imported Upstream version 5.1.0
Diffstat (limited to 'src/libstrongswan/plugins/unbound/unbound_plugin.c')
| -rw-r--r-- | src/libstrongswan/plugins/unbound/unbound_plugin.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/libstrongswan/plugins/unbound/unbound_plugin.c b/src/libstrongswan/plugins/unbound/unbound_plugin.c index 90b95330a..f727cdaae 100644 --- a/src/libstrongswan/plugins/unbound/unbound_plugin.c +++ b/src/libstrongswan/plugins/unbound/unbound_plugin.c @@ -37,10 +37,20 @@ METHOD(plugin_t, get_name, char*, return "unbound"; } +METHOD(plugin_t, get_features, int, + private_unbound_plugin_t *this, plugin_feature_t *features[]) +{ + static plugin_feature_t f[] = { + PLUGIN_REGISTER(RESOLVER, unbound_resolver_create), + PLUGIN_PROVIDE(RESOLVER), + }; + *features = f; + return countof(f); +} + METHOD(plugin_t, destroy, void, private_unbound_plugin_t *this) { - lib->resolver->remove_resolver(lib->resolver, unbound_resolver_create); free(this); } @@ -55,12 +65,11 @@ plugin_t *unbound_plugin_create() .public = { .plugin = { .get_name = _get_name, + .get_features = _get_features, .destroy = _destroy, }, }, ); - lib->resolver->add_resolver(lib->resolver, unbound_resolver_create); - return &this->public.plugin; } |
