diff options
author | Jan Schmidt <thaytan@noraisin.net> | 2009-10-08 10:36:56 +0100 |
---|---|---|
committer | Jan Schmidt <thaytan@noraisin.net> | 2009-10-08 10:36:56 +0100 |
commit | f514ef0efc8df863b2b83e5cdedb48d3a487d28d (patch) | |
tree | ce03d903e558ca8e428d5ae2a3c865c4440364d6 /gst/gstregistry.c | |
parent | 509e1fdf0efae4d5eac3fe2204b5e5e890fa4fd1 (diff) |
registry: Fix error handling in the registry loader
When the plugin-scanner load fails (because the helper can't be
spawned), make sure to load the plugin that failed in-process, so
that all plugins do get loaded.
Diffstat (limited to 'gst/gstregistry.c')
-rw-r--r-- | gst/gstregistry.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/gst/gstregistry.c b/gst/gstregistry.c index ac5598e035..58b5c5504f 100644 --- a/gst/gstregistry.c +++ b/gst/gstregistry.c @@ -882,8 +882,10 @@ gst_registry_scan_plugin_file (GstRegistryScanContext * context, context->helper = _priv_gst_plugin_loader_funcs.create (context->registry); if (context->helper != NULL) context->helper_state = REGISTRY_SCAN_HELPER_RUNNING; - else + else { + GST_WARNING ("Failed starting plugin scanner. Scanning in-process"); context->helper_state = REGISTRY_SCAN_HELPER_DISABLED; + } } if (context->helper_state == REGISTRY_SCAN_HELPER_RUNNING) { @@ -898,7 +900,10 @@ gst_registry_scan_plugin_file (GstRegistryScanContext * context, "GST_PLUGIN_SCANNER environment variable gets set." : ""); context->helper_state = REGISTRY_SCAN_HELPER_DISABLED; } - } else { + } + + /* Check if the helper is disabled (or just got disabled above) */ + if (context->helper_state == REGISTRY_SCAN_HELPER_DISABLED) { /* Load plugin the old fashioned way... */ /* We don't use a GError here because a failure to load some shared |