[vlc-commits] mmal/vout: Use default allocator for mmal pool
Julian Scheel
git at videolan.org
Thu Sep 4 18:22:26 CEST 2014
vlc | branch: master | Julian Scheel <julian at jusst.de> | Thu Sep 4 12:55:12 2014 +0200| [2eccb60b5be0cd8452d8e247410e8521dc3d515f] | committer: Jean-Baptiste Kempf
mmal/vout: Use default allocator for mmal pool
The port agnostic allocator helpers in mmal leak memory (see
https://github.com/raspberrypi/firmware/issues/310). As there is no benefit
using them instead of the default allocator in our case anyway, switch to the
default allocator, which avoids memory leakage on pool destruction.
Signed-off-by: Julian Scheel <julian at jusst.de>
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=2eccb60b5be0cd8452d8e247410e8521dc3d515f
---
modules/hw/mmal/vout.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/modules/hw/mmal/vout.c b/modules/hw/mmal/vout.c
index b024f30..1a7825d 100644
--- a/modules/hw/mmal/vout.c
+++ b/modules/hw/mmal/vout.c
@@ -456,10 +456,7 @@ static picture_pool_t *vd_pool(vout_display_t *vd, unsigned count)
}
sys->num_buffers = count;
- sys->pool = mmal_pool_create_with_allocator(sys->num_buffers, sys->input->buffer_size,
- sys->input,
- (mmal_pool_allocator_alloc_t)mmal_port_payload_alloc,
- (mmal_pool_allocator_free_t)mmal_port_payload_free);
+ sys->pool = mmal_pool_create(sys->num_buffers, sys->input->buffer_size);
if (!sys->pool) {
msg_Err(vd, "Failed to create MMAL pool for %u buffers of size %"PRIu32,
count, sys->input->buffer_size);
More information about the vlc-commits
mailing list