basertppayload: Reject empty caps
authorOlivier CrĂȘte <olivier.crete@collabora.co.uk>
Mon, 18 Jan 2010 19:33:30 +0000 (14:33 -0500)
committerWim Taymans <wim.taymans@collabora.co.uk>
Tue, 19 Jan 2010 12:29:19 +0000 (13:29 +0100)
https://bugzilla.gnome.org/show_bug.cgi?id=607353

gst-libs/gst/rtp/gstbasertppayload.c

index a6d8eb3..ed5accc 100644 (file)
@@ -556,6 +556,11 @@ gst_basertppayload_set_outcaps (GstBaseRTPPayload * payload, gchar * fieldname,
     gst_caps_unref (srccaps);
     gst_caps_unref (peercaps);
 
+    if (gst_caps_is_empty (temp)) {
+      gst_caps_unref (temp);
+      return FALSE;
+    }
+
     /* now fixate, start by taking the first caps */
     gst_caps_truncate (temp);