decoder: enable decoders even if they have no init() method
Commit 1a4a3e1f
moved decoders into a static array, but failed to
enable those plugins who did not have an init() method at all.
This patch corrects the "enabled" check.
This commit is contained in:
parent
4c1b96c307
commit
b48ae8c26f
@ -165,7 +165,7 @@ void decoder_plugin_init_all(void)
|
|||||||
{
|
{
|
||||||
for (unsigned i = 0; i < num_decoder_plugins; ++i) {
|
for (unsigned i = 0; i < num_decoder_plugins; ++i) {
|
||||||
const struct decoder_plugin *plugin = decoder_plugins[i];
|
const struct decoder_plugin *plugin = decoder_plugins[i];
|
||||||
if (plugin->init != NULL && decoder_plugins[i]->init())
|
if (plugin->init == NULL || decoder_plugins[i]->init())
|
||||||
decoder_plugins_enabled[i] = true;
|
decoder_plugins_enabled[i] = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user