diff options
Diffstat (limited to 'src/main/extractor_plugins.c')
-rw-r--r-- | src/main/extractor_plugins.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/main/extractor_plugins.c b/src/main/extractor_plugins.c index 3e77bae..ddff7d9 100644 --- a/src/main/extractor_plugins.c +++ b/src/main/extractor_plugins.c | |||
@@ -208,7 +208,7 @@ EXTRACTOR_plugin_add (struct EXTRACTOR_PluginList *prev, | |||
208 | const char *options, | 208 | const char *options, |
209 | enum EXTRACTOR_Options flags) | 209 | enum EXTRACTOR_Options flags) |
210 | { | 210 | { |
211 | struct EXTRACTOR_PluginList *result; | 211 | struct EXTRACTOR_PluginList *plugin; |
212 | struct EXTRACTOR_PluginList *pos; | 212 | struct EXTRACTOR_PluginList *pos; |
213 | char *libname; | 213 | char *libname; |
214 | 214 | ||
@@ -221,22 +221,23 @@ EXTRACTOR_plugin_add (struct EXTRACTOR_PluginList *prev, | |||
221 | library); | 221 | library); |
222 | return prev; | 222 | return prev; |
223 | } | 223 | } |
224 | if (NULL == (result = malloc (sizeof (struct EXTRACTOR_PluginList)))) | 224 | if (NULL == (plugin = malloc (sizeof (struct EXTRACTOR_PluginList)))) |
225 | return prev; | 225 | return prev; |
226 | memset (result, 0, sizeof (struct EXTRACTOR_PluginList)); | 226 | memset (plugin, 0, sizeof (struct EXTRACTOR_PluginList)); |
227 | result->next = prev; | 227 | plugin->next = prev; |
228 | if (NULL == (result->short_libname = strdup (library))) | 228 | if (NULL == (plugin->short_libname = strdup (library))) |
229 | { | 229 | { |
230 | free (result); | 230 | free (plugin); |
231 | return NULL; | 231 | return NULL; |
232 | } | 232 | } |
233 | result->libname = libname; | 233 | plugin->libname = libname; |
234 | result->flags = flags; | 234 | plugin->flags = flags; |
235 | if (NULL != options) | 235 | if (NULL != options) |
236 | result->plugin_options = strdup (options); | 236 | plugin->plugin_options = strdup (options); |
237 | else | 237 | else |
238 | result->plugin_options = NULL; | 238 | plugin->plugin_options = NULL; |
239 | return result; | 239 | plugin->seek_request = -1; |
240 | return plugin; | ||
240 | } | 241 | } |
241 | 242 | ||
242 | 243 | ||