Not a clue, but since this hasn't been picked up:
How do the reference and example decoders handle these files?
Is dwBufferLength the allocated length or the attempted write
length? Can you trace into vorbis_synthesis and see how
much is being allocated?
imalone
Steve Russell wrote:> I wonder if anyone would have a comment on an experiment I have pretty much
completed in my MFC/C++ project. With my simple libvorbis implementation, ogg
decoding works just fine for files that are 10kb or larger. For anything
smaller (actually, I don't have a 9kb file, so <= 8), it seems that I get
an inaccurate value for ov_pcm_total. Though ov_read returns zero, I overflow
the buffer and crash on ov_clear. These are my TRACE statements:
>
>
>>= 10kb:
>
>
> Opening Audio File 'no_0.ogg'
> vi->channels = '2'
> vi->rate = '44100'
> pcmTotal = '15341'
> pcmTotal * vi->channels * 2 = '61364'
> BufferSize = '61364'
> dwBufferLength = '61364'
> BufferSize = '61364'
> dwBufferLength - BufferSize = '0'
> ------------
> < 10kb:
>
> Opening Audio File 'Steel guitar_4.ogg'
> vi->channels = '2'
> vi->rate = '44100'
> pcmTotal = '9876'
> pcmTotal * vi->channels * 2 = '39504'
> BufferSize = '39504'
> dwBufferLength = '43264'
> BufferSize = '39504'
> dwBufferLength - BufferSize = '3760'
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Vorbis-dev mailing list
> Vorbis-dev@xiph.org
> http://lists.xiph.org/mailman/listinfo/vorbis-dev