aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2011-09-09 19:45:31 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2011-09-09 19:46:02 +0800
commitc785ff79365fb91a41e38458ae6ea5cf02cbaa8f (patch)
treeb06978e6c9b7b1e89178b990235b09888640e820
parent890efc4f52b81bf90fb5d130124d68fe071abc3f (diff)
downloadgsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar.gz
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar.bz2
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar.lz
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar.xz
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.tar.zst
gsoc2013-empathy-c785ff79365fb91a41e38458ae6ea5cf02cbaa8f.zip
dup_color_balance: check that element currently implements GstColorBalance
https://bugzilla.gnome.org/show_bug.cgi?id=658584
-rw-r--r--src/empathy-video-src.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/empathy-video-src.c b/src/empathy-video-src.c
index da86eda93..ca8370d82 100644
--- a/src/empathy-video-src.c
+++ b/src/empathy-video-src.c
@@ -256,6 +256,15 @@ dup_color_balance (GstElement *src)
if (color == NULL)
return NULL;
+ /* colorbalance is wrapped by GstImplementsInterface, we
+ * need to check if it is actually supported for this instance
+ * in its current state before trying to use it */
+ if (!GST_IS_COLOR_BALANCE (color))
+ {
+ g_object_unref (color);
+ return NULL;
+ }
+
return GST_COLOR_BALANCE (color);
}