commit 1bb9a69d15f18268748e94b06bb88dd8636624de
parent 4183d2ea76ca0f9eca41ea46776361c41a362f96
Author: LRN <lrn1986@gmail.com>
Date: Fri, 3 Aug 2012 22:35:36 +0000
Fix (somewhat) in-process plugin handling
Diffstat:
1 file changed, 5 insertions(+), 0 deletions(-)
diff --git a/src/main/extractor.c b/src/main/extractor.c
@@ -517,10 +517,15 @@ do_extract (struct EXTRACTOR_PluginList *plugins,
ec.seek = &in_process_seek;
ec.get_size = &in_process_get_size;
ec.proc = &in_process_proc;
+ if (-1 == EXTRACTOR_datasource_seek_ (ds, 0, SEEK_SET))
+ return;
+
for (pos = plugins; NULL != pos; pos = pos->next)
{
if (EXTRACTOR_OPTION_IN_PROCESS != pos->flags)
continue;
+ if (-1 == EXTRACTOR_plugin_load_ (pos))
+ continue;
ctx.plugin = pos;
ec.config = pos->plugin_options;
pos->extract_method (&ec);