summaryrefslogtreecommitdiff
path: root/gst-libs
diff options
context:
space:
mode:
authorEdward Hervey <bilboed@bilboed.com>2010-10-24 15:38:30 +0200
committerEdward Hervey <bilboed@bilboed.com>2010-10-24 16:19:09 +0200
commitda9682a593723db926ab5e0c083bdc8f1c17e17f (patch)
tree2e04cb46e89589dbb2596fbf3c439b951dde260d /gst-libs
parenta5752d8ea733d792c650d33063e733831ce34277 (diff)
discoverer: Don't ref a NULL caps
https://bugzilla.gnome.org/show_bug.cgi?id=632988
Diffstat (limited to 'gst-libs')
-rw-r--r--gst-libs/gst/pbutils/gstdiscoverer-types.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gst-libs/gst/pbutils/gstdiscoverer-types.c b/gst-libs/gst/pbutils/gstdiscoverer-types.c
index b4c51c37a..b7c978ca6 100644
--- a/gst-libs/gst/pbutils/gstdiscoverer-types.c
+++ b/gst-libs/gst/pbutils/gstdiscoverer-types.c
@@ -539,7 +539,9 @@ gst_discoverer_stream_info_get_caps (GstDiscovererStreamInfo * info)
{
g_return_val_if_fail (GST_IS_DISCOVERER_STREAM_INFO (info), NULL);
- return gst_caps_ref (info->caps);
+ if (info->caps)
+ return gst_caps_ref (info->caps);
+ return NULL;
}
/**