From 21e9f844868a07259508eb6c4812662a61d55e65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Mon, 25 Aug 2014 15:15:06 +0300 Subject: [PATCH] decodebin: Remove error case that resulted in two error messages We already send one in gst_decode_bin_expose() for this case. Only if we're unable to typefind the caps another error message is needed. --- gst/playback/gstdecodebin2.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/gst/playback/gstdecodebin2.c b/gst/playback/gstdecodebin2.c index bc3d18d7ec..2ac1c0f8d3 100644 --- a/gst/playback/gstdecodebin2.c +++ b/gst/playback/gstdecodebin2.c @@ -1822,20 +1822,9 @@ unknown_type: EXPOSE_UNLOCK (dbin); if (src == dbin->typefind) { - gchar *desc; - - if (caps && !gst_caps_is_empty (caps)) { - desc = gst_pb_utils_get_decoder_description (caps); - GST_ELEMENT_ERROR (dbin, STREAM, CODEC_NOT_FOUND, - (_("A %s plugin is required to play this stream, " - "but not installed."), desc), - ("No decoder to handle media type '%s'", - gst_structure_get_name (gst_caps_get_structure (caps, 0)))); - g_free (desc); - } else { + if (!caps || gst_caps_is_empty (caps)) { GST_ELEMENT_ERROR (dbin, STREAM, TYPE_NOT_FOUND, - (_("Could not determine type of stream")), - ("Stream caps %" GST_PTR_FORMAT, caps)); + (_("Could not determine type of stream")), (NULL)); } do_async_done (dbin); }