summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2010-04-05 19:22:50 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2010-04-05 19:22:50 (GMT)
commit929150f18d23d82e8390bd98e31b1edb34bc09f1 (patch)
treed33ca3b894dd9c7cc714a6eac696fade2b813cdf /src/plugins
parentc853ed6c88a82e2859033c4111b0edb0372bc570 (diff)
Created a plugin to follow the control.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@149 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/plugin-def.h5
-rw-r--r--src/plugins/plugin.c5
2 files changed, 4 insertions, 6 deletions
diff --git a/src/plugins/plugin-def.h b/src/plugins/plugin-def.h
index 1b47bd6..adbabd4 100644
--- a/src/plugins/plugin-def.h
+++ b/src/plugins/plugin-def.h
@@ -41,14 +41,11 @@ typedef enum _PluginAction
-struct _GPluginModule;
-
-
/* Fournit une indication sur le type d'opération(s) menée(s). */
typedef PluginAction (* get_plugin_action_fc) (void);
/* Exécute une action définie sur un binaire chargé. */
-typedef bool (* execute_action_on_binary_fc) (struct _GPluginModule *, GOpenidaBinary *, PluginAction);
+typedef bool (* execute_action_on_binary_fc) (GOpenidaBinary *, PluginAction);
diff --git a/src/plugins/plugin.c b/src/plugins/plugin.c
index ed4c39d..42bef63 100644
--- a/src/plugins/plugin.c
+++ b/src/plugins/plugin.c
@@ -107,7 +107,7 @@ GPluginModule *g_plugin_module_new(const gchar *filename, GObject *ref)
result->module = g_module_open(filename, G_MODULE_BIND_LAZY);
-#if 0
+#if 1
if (!g_module_symbol(result->module, "get_plugin_action", (gpointer *)&__get_action))
{
printf("Err plugin get_action sym\n");
@@ -144,6 +144,7 @@ GPluginModule *g_plugin_module_new(const gchar *filename, GObject *ref)
if (!result->init(ref))
printf("Err loading pg\n");
+ else printf("Loaded '%s' : ok (%p)\n", filename, result);
return result;
@@ -185,6 +186,6 @@ PluginAction g_plugin_module_get_action(const GPluginModule *plugin)
bool g_plugin_module_execute_action_on_binary(const GPluginModule *plugin, GOpenidaBinary *binary, PluginAction action)
{
- return plugin->exec_on_bin(plugin, binary, action);
+ return plugin->exec_on_bin(binary, action);
}