mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
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:
parent
8ec2e0ad62
commit
5109d9930c
1 changed files with 2 additions and 3 deletions
|
@ -207,10 +207,9 @@ static gboolean
|
||||||
gst_openh264dec_stop (GstVideoDecoder * decoder)
|
gst_openh264dec_stop (GstVideoDecoder * decoder)
|
||||||
{
|
{
|
||||||
GstOpenh264Dec *openh264dec = GST_OPENH264DEC (decoder);
|
GstOpenh264Dec *openh264dec = GST_OPENH264DEC (decoder);
|
||||||
gint ret = TRUE;
|
|
||||||
|
|
||||||
if (openh264dec->priv->decoder) {
|
if (openh264dec->priv->decoder) {
|
||||||
ret = openh264dec->priv->decoder->Uninitialize ();
|
openh264dec->priv->decoder->Uninitialize ();
|
||||||
WelsDestroyDecoder (openh264dec->priv->decoder);
|
WelsDestroyDecoder (openh264dec->priv->decoder);
|
||||||
openh264dec->priv->decoder = NULL;
|
openh264dec->priv->decoder = NULL;
|
||||||
}
|
}
|
||||||
|
@ -221,7 +220,7 @@ gst_openh264dec_stop (GstVideoDecoder * decoder)
|
||||||
}
|
}
|
||||||
openh264dec->priv->width = openh264dec->priv->height = 0;
|
openh264dec->priv->width = openh264dec->priv->height = 0;
|
||||||
|
|
||||||
return ret;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
|
Loading…
Reference in a new issue