mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-06 23:48:53 +00:00
faad: do not access frame buffer following _finish_frame call
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=680494
This commit is contained in:
parent
a48cfea4a2
commit
19ca77e95e
1 changed files with 3 additions and 2 deletions
|
@ -749,6 +749,9 @@ init:
|
||||||
|
|
||||||
out = faacDecDecode (faad->handle, &info, input_data, input_size);
|
out = faacDecDecode (faad->handle, &info, input_data, input_size);
|
||||||
|
|
||||||
|
gst_buffer_unmap (buffer, &map);
|
||||||
|
buffer = NULL;
|
||||||
|
|
||||||
if (info.error > 0) {
|
if (info.error > 0) {
|
||||||
/* give up on frame and bail out */
|
/* give up on frame and bail out */
|
||||||
gst_audio_decoder_finish_frame (dec, NULL, 1);
|
gst_audio_decoder_finish_frame (dec, NULL, 1);
|
||||||
|
@ -792,8 +795,6 @@ init:
|
||||||
memcpy (omap.data, out, omap.size);
|
memcpy (omap.data, out, omap.size);
|
||||||
}
|
}
|
||||||
gst_buffer_unmap (outbuf, &omap);
|
gst_buffer_unmap (outbuf, &omap);
|
||||||
gst_buffer_unmap (buffer, &map);
|
|
||||||
buffer = NULL;
|
|
||||||
|
|
||||||
ret = gst_audio_decoder_finish_frame (dec, outbuf, 1);
|
ret = gst_audio_decoder_finish_frame (dec, outbuf, 1);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue