GNOME Bugzilla – Bug 671047
[discoverer] don't change result when processing missing plugin errors
Last modified: 2012-03-03 13:58:13 UTC
When no decoder is available for the file being discovered, GstDiscoverer ends up with result == GST_DISCOVERER_ERROR rather than GST_DISCOVERER_MISSING_PLUGINS because it gets a couple of error messages after the missing plugin message. It'd be more useful if it kept the GST_DISCOVERER_MISSING_PLUGINS result in this case.
Created attachment 208673 [details] [review] don't change result when processing missing plugin errors don't change result when processing a GST_CORE_ERROR_MISSING_PLUGIN error and the result is currently GST_DISCOVERER_MISSING_PLUGINS.
Thanks! IMHO there's still something a bit dodgy about all of this. I think the GError should be set/overwritten alongside the return value as needed, but there's clearly a bug here, and the patch fixes that, so let's do that for now. I've changed it slightly to also consider STREAM_CODEC_NOT_FOUND errors which are like CORE_MISSING_PLUGIN. Hope I didn't mess anything up. commit 85a7b8f5622536de9b888f58c7c6ca1b15834b78 Author: Tim-Philipp Müller <tim.muller@collabora.co.uk> Date: Sat Mar 3 13:51:55 2012 +0000 tests: add test to check discoverer return code for missing plugins case https://bugzilla.gnome.org/show_bug.cgi?id=671047 commit bc1fb43408520e62661598d63ece648801e06f41 Author: Jonathan Matthew <jonathan@d14n.org> Date: Wed Feb 29 21:25:24 2012 +1000 discoverer: don't change result for missing plugin errors https://bugzilla.gnome.org/show_bug.cgi?id=671047