Mercurial > mplayer.hg
changeset 21509:18d525833180
vorbis_comment is only used locally, move it out of demuxer struct
author | reimar |
---|---|
date | Thu, 07 Dec 2006 12:02:51 +0000 |
parents | 63b3fbf90106 |
children | 5f8a9c31c0b6 |
files | libmpdemux/demux_ogg.c |
diffstat | 1 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_ogg.c Thu Dec 07 12:02:01 2006 +0000 +++ b/libmpdemux/demux_ogg.c Thu Dec 07 12:02:51 2006 +0000 @@ -131,7 +131,6 @@ char **text_langs; vorbis_info vi; - vorbis_comment vc; int vi_inited; } ogg_demuxer_t; @@ -749,9 +748,10 @@ unsigned char *buf[3]; unsigned char *ptr; unsigned int len; + vorbis_comment vc; vorbis_info_init(&od->vi); - vorbis_comment_init(&od->vc); + vorbis_comment_init(&vc); for(i = 0; i < 3; i++) { op[i].bytes = ds_get_packet(sh->ds, &(op[i].packet)); mp_msg(MSGT_DEMUX,MSGL_V, "fixup_vorbis_wf: i=%d, size=%ld\n", i, op[i].bytes); @@ -765,12 +765,13 @@ memcpy(buf[i], op[i].packet, op[i].bytes); op[i].b_o_s = (i==0); - ris = vorbis_synthesis_headerin(&(od->vi),&(od->vc),&(op[i])); + ris = vorbis_synthesis_headerin(&(od->vi),&vc,&(op[i])); if(ris < 0) { init_error = 1; mp_msg(MSGT_DECAUDIO,MSGL_ERR,"DEMUX_OGG: header n. %d broken! len=%ld, code: %d\n", i, op[i].bytes, ris); } } + vorbis_comment_clear(&vc); if(!init_error) od->vi_inited = 1; @@ -1610,7 +1611,6 @@ free(ogg_d->text_langs); } vorbis_info_clear(&ogg_d->vi); - vorbis_comment_clear(&ogg_d->vc); free(ogg_d); }