audioencoder: Error-handling for pushing headers

https://bugzilla.gnome.org/show_bug.cgi?id=773105
This commit is contained in:
Havard Graff 2015-12-04 00:47:38 +11:00 committed by Sebastian Dröge
parent 92392a4733
commit a32b25db6a

View file

@ -921,7 +921,12 @@ gst_audio_encoder_finish_frame (GstAudioEncoder * enc, GstBuffer * buf,
priv->bytes_out += size;
GST_OBJECT_UNLOCK (enc);
gst_pad_push (enc->srcpad, tmpbuf);
ret = gst_pad_push (enc->srcpad, tmpbuf);
if (ret != GST_FLOW_OK) {
GST_WARNING_OBJECT (enc, "pushing header returned %s",
gst_flow_get_name (ret));
goto exit;
}
}
priv->ctx.new_headers = FALSE;
}