mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 00:36:51 +00:00
omxvideoenc: Don't forget to unmap frame in error cases
This commit is contained in:
parent
25d5c55764
commit
bcb181bd2d
1 changed files with 2 additions and 0 deletions
|
@ -1162,6 +1162,7 @@ gst_omx_video_enc_fill_buffer (GstOMXVideoEnc * self, GstBuffer * inbuf,
|
|||
|
||||
if (dest + dest_stride * height >
|
||||
outbuf->omx_buf->pBuffer + outbuf->omx_buf->nAllocLen) {
|
||||
gst_video_frame_unmap (&frame);
|
||||
GST_ERROR_OBJECT (self, "Invalid output buffer size");
|
||||
ret = FALSE;
|
||||
break;
|
||||
|
@ -1219,6 +1220,7 @@ gst_omx_video_enc_fill_buffer (GstOMXVideoEnc * self, GstBuffer * inbuf,
|
|||
|
||||
if (dest + dest_stride * height >
|
||||
outbuf->omx_buf->pBuffer + outbuf->omx_buf->nAllocLen) {
|
||||
gst_video_frame_unmap (&frame);
|
||||
GST_ERROR_OBJECT (self, "Invalid output buffer size");
|
||||
ret = FALSE;
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue