gme: Free decoder instance when going from PAUSED to READY

We only ever cleaned it up before on errors.
This commit is contained in:
Sebastian Dröge 2016-12-13 20:42:44 +02:00
parent fbf7e905f0
commit 7360c93de1

View file

@ -489,6 +489,10 @@ gst_gme_dec_change_state (GstElement * element, GstStateChange transition)
switch (transition) {
case GST_STATE_CHANGE_PAUSED_TO_READY:
gst_adapter_clear (dec->adapter);
if (dec->player) {
gme_delete (dec->player);
dec->player = NULL;
}
break;
default:
break;