controller: Do not unset uninitiallized GValue

In case the property was not interpollable we might never initialize
the GValue, we should thus never unset it.
This commit is contained in:
Thibault Saunier 2016-02-02 16:35:34 +01:00
parent 81df1e1a34
commit 438a83df58

View file

@ -343,7 +343,8 @@ gst_direct_control_binding_finalize (GObject * object)
{
GstDirectControlBinding *self = GST_DIRECT_CONTROL_BINDING (object);
g_value_unset (&self->cur_value);
if (G_IS_VALUE (&self->cur_value))
g_value_unset (&self->cur_value);
G_OBJECT_CLASS (parent_class)->finalize (object);
}