Skip to content
Myr

fixed vorbis comments causing outofmem

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by AnthoFoxo · committed by AnthoFoxo · parent 4882970 · Browse files · 1 file+4 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−2 removed

  • other:+4 added−2 removed

1 file+4 added−2 removed

modified:stb_vorbis.c+4 added-2 removed
3643 unmodified lines
3644 //user comments3645 f->comment_list_length = get32_packet(f);3646 f->comment_list = NULL;3647 if (f->comment_list_length > 0)3648 {3648 f->comment_list = (char**) setup_malloc(f, sizeof(char*) * (f->comment_list_length));3649 if (f->comment_list == NULL) return error(f, VORBIS_outofmem);3649 f->comment_list = (char**) setup_malloc(f, sizeof(char*) * (f->comment_list_length));3650 if (f->comment_list == NULL) return error(f, VORBIS_outofmem);3651 }36523653 for(i=0; i < f->comment_list_length; ++i) {3654 len = get32_packet(f);3655 f->comment_list[i] = (char*)setup_malloc(f, sizeof(char) * (len+1));
1913 unmodified lines