summaryrefslogtreecommitdiffstats
path: root/plugin.c
diff options
context:
space:
mode:
authorDavid Sommerseth <dazo@users.sourceforge.net>2010-12-10 00:09:20 +0100
committerDavid Sommerseth <davids@redhat.com>2011-03-25 09:38:48 +0100
commit6b2e3b9132e5820cebf4984c86ef742c11587790 (patch)
tree2fa11dc5c7b2e7ae22c34876a8546f0f6210fa8c /plugin.c
parenta0a547a70d6f8e5cc444fe6b07020d874cca1418 (diff)
downloadopenvpn-6b2e3b9132e5820cebf4984c86ef742c11587790.tar.gz
openvpn-6b2e3b9132e5820cebf4984c86ef742c11587790.tar.xz
openvpn-6b2e3b9132e5820cebf4984c86ef742c11587790.zip
Define the new openvpn_plugin_{open,func}_v3() API
This just implements the basic API changes needed for the newer and more flexible plug-in API. Signed-off-by: David Sommerseth <dazo@users.sourceforge.net> Acked-by: James Yonan <james@openvpn.net>
Diffstat (limited to 'plugin.c')
-rw-r--r--plugin.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugin.c b/plugin.c
index 0d66611..374abc6 100644
--- a/plugin.c
+++ b/plugin.c
@@ -232,8 +232,10 @@ plugin_init_item (struct plugin *p, const struct plugin_option *o)
PLUGIN_SYM (open1, "openvpn_plugin_open_v1", 0);
PLUGIN_SYM (open2, "openvpn_plugin_open_v2", 0);
+ PLUGIN_SYM (open3, "openvpn_plugin_open_v3", 0);
PLUGIN_SYM (func1, "openvpn_plugin_func_v1", 0);
PLUGIN_SYM (func2, "openvpn_plugin_func_v2", 0);
+ PLUGIN_SYM (func3, "openvpn_plugin_func_v3", 0);
PLUGIN_SYM (close, "openvpn_plugin_close_v1", PLUGIN_SYMBOL_REQUIRED);
PLUGIN_SYM (abort, "openvpn_plugin_abort_v1", 0);
PLUGIN_SYM (client_constructor, "openvpn_plugin_client_constructor_v1", 0);
@@ -241,10 +243,10 @@ plugin_init_item (struct plugin *p, const struct plugin_option *o)
PLUGIN_SYM (min_version_required, "openvpn_plugin_min_version_required_v1", 0);
PLUGIN_SYM (initialization_point, "openvpn_plugin_select_initialization_point_v1", 0);
- if (!p->open1 && !p->open2)
+ if (!p->open1 && !p->open2 && !p->open3)
msg (M_FATAL, "PLUGIN: symbol openvpn_plugin_open_vX is undefined in plugin: %s", p->so_pathname);
- if (!p->func1 && !p->func2)
+ if (!p->func1 && !p->func2 && !p->func3)
msg (M_FATAL, "PLUGIN: symbol openvpn_plugin_func_vX is undefined in plugin: %s", p->so_pathname);
/*