openh264dec: Uninitializing the decoder can't fail and will always return 0 == cmResultSuccess

... but when we cast cmResultSuccess to a gboolean it will be FALSE, and make
GstVideoDecoder::stop() fail for no reason.
This commit is contained in:
Sebastian Dröge 2015-07-02 14:15:05 +02:00
parent 8ec2e0ad62
commit 5109d9930c

View file

@ -207,10 +207,9 @@ static gboolean
gst_openh264dec_stop (GstVideoDecoder * decoder)
{
GstOpenh264Dec *openh264dec = GST_OPENH264DEC (decoder);
gint ret = TRUE;
if (openh264dec->priv->decoder) {
ret = openh264dec->priv->decoder->Uninitialize ();
openh264dec->priv->decoder->Uninitialize ();
WelsDestroyDecoder (openh264dec->priv->decoder);
openh264dec->priv->decoder = NULL;
}
@ -221,7 +220,7 @@ gst_openh264dec_stop (GstVideoDecoder * decoder)
}
openh264dec->priv->width = openh264dec->priv->height = 0;
return ret;
return TRUE;
}
static gboolean