2011/11/7 G?bor Kov?cs <picard at movelex.hu>:> Hi,
>
> As far as I see in libvorbis most of the places where _ogg_malloc(),
> _ogg_realloc and _ogg_calloc() is called the return value is not checked
for
> out of memory condition. Is there any plan to change this?
Yes, in fact, for embedded systems.
> For my use-case the application is not allowed to crash. So if libvorbis
can
> not handle this condition, I guess I would need to preallocate a large
> enough custom memory heap for all kind of vorbis files and override the ogg
> allocation macros.
On most general purpose systems, mallocs can't return NULL unless the
heap is corrupted. Of course, that's not true for embedded and
special use OSes, so the code is in fact scheduled to change.
Monty