From 2fbf09752d385af861279af195d68f920859202d Mon Sep 17 00:00:00 2001 From: Andrew Mahone Date: Tue, 13 Jan 2009 13:48:26 +0000 Subject: remove align_buffer from firmare/general.c, replacing with ALIGN_BUFFER macro, and replace all uses of it (only resize.c in core, and pictureflow and mpegplayer plugins), remove it from plugin_api, and remove wrapper for it from plugin.h git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19758 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/mpegplayer/alloc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'apps/plugins/mpegplayer/alloc.c') diff --git a/apps/plugins/mpegplayer/alloc.c b/apps/plugins/mpegplayer/alloc.c index c4f936e..6b50b8f 100644 --- a/apps/plugins/mpegplayer/alloc.c +++ b/apps/plugins/mpegplayer/alloc.c @@ -27,6 +27,7 @@ #include "plugin.h" #include "mpegplayer.h" +#include /* Main allocator */ static off_t mem_ptr; @@ -132,8 +133,8 @@ bool mpeg_alloc_init(unsigned char *buf, size_t mallocsize) mem_ptr = 0; /* Cache-align buffer or 4-byte align */ mallocbuf = buf; - bufsize = align_buffer(PUN_PTR(void **, &mallocbuf), - mallocsize, CACHEALIGN_UP(4)); + bufsize = mallocsize; + ALIGN_BUFFER(mallocbuf, bufsize, CACHEALIGN_UP(4)); /* Separate allocator for video */ mpeg2_mem_ptr = 0; -- cgit v1.1