commit 8db62389610eac72b690dd8b31c82a700df3023d
parent 8f22cab9b95402d1c9cf6ec1a1016f593fb914dc
Author: Christian Grothoff <christian@grothoff.org>
Date: Tue, 15 Dec 2009 10:32:07 +0000
fix
Diffstat:
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/src/main/extractor.c b/src/main/extractor.c
@@ -1170,7 +1170,8 @@ extract_oop (struct EXTRACTOR_PluginList *plugin,
{
stop_process (plugin);
plugin->cpid = -1;
- plugin->flags = EXTRACTOR_OPTION_DISABLED;
+ if (plugin->flags != EXTRACTOR_OPTION_AUTO_RESTART)
+ plugin->flags = EXTRACTOR_OPTION_DISABLED;
return 0;
}
while (1)
@@ -1179,8 +1180,9 @@ extract_oop (struct EXTRACTOR_PluginList *plugin,
&hdr,
sizeof(hdr)))
{
+ if (plugin->flags != EXTRACTOR_OPTION_AUTO_RESTART)
+ plugin->flags = EXTRACTOR_OPTION_DISABLED;
return 0;
- plugin->flags = EXTRACTOR_OPTION_DISABLED;
}
if ( (hdr.type == 0) &&
(hdr.format == 0) &&
@@ -1190,7 +1192,8 @@ extract_oop (struct EXTRACTOR_PluginList *plugin,
if (hdr.mime_len > MAX_MIME_LEN)
{
stop_process (plugin);
- plugin->flags = EXTRACTOR_OPTION_DISABLED;
+ if (plugin->flags != EXTRACTOR_OPTION_AUTO_RESTART)
+ plugin->flags = EXTRACTOR_OPTION_DISABLED;
return 0;
}
data = malloc (hdr.data_len);
@@ -1208,7 +1211,8 @@ extract_oop (struct EXTRACTOR_PluginList *plugin,
{
stop_process (plugin);
free (data);
- plugin->flags = EXTRACTOR_OPTION_DISABLED;
+ if (plugin->flags != EXTRACTOR_OPTION_AUTO_RESTART)
+ plugin->flags = EXTRACTOR_OPTION_DISABLED;
return 0;
}
mimetype[hdr.mime_len] = '\0';