forked from len0rd/rockbox
iriver: fix problem with playing some long vorbis files (e.g., this week in tech, #21); the decoder would run out of memory and freeze rockbox.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7526 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
59c995f58b
commit
f5ec0fa592
4 changed files with 19 additions and 4 deletions
|
|
@ -29,16 +29,21 @@
|
|||
* be implemented elsewhere */
|
||||
#define malloc(x) codec_malloc(x)
|
||||
#define calloc(x,y) codec_calloc(x,y)
|
||||
#define alloca(x) codec_alloca(x)
|
||||
#define realloc(x,y) codec_realloc(x,y)
|
||||
#define free(x) codec_free(x)
|
||||
|
||||
void* codec_malloc(size_t size);
|
||||
void* codec_calloc(size_t nmemb, size_t size);
|
||||
void* codec_alloca(size_t size);
|
||||
void* codec_realloc(void* ptr, size_t size);
|
||||
void codec_free(void* ptr);
|
||||
|
||||
#if !defined(SIMULATOR)
|
||||
#define alloca __builtin_alloca
|
||||
#else
|
||||
#define alloca(x) codec_alloca(x)
|
||||
void* codec_alloca(size_t size);
|
||||
#endif
|
||||
|
||||
#define abs(x) ((x)>0?(x):-(x))
|
||||
#define labs(x) abs(x)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue