[FFmpeg-devel] [PATCH] wavdec: Fix duration calculation for files with invalid data size
James Almer
jamrial at gmail.com
Fri Dec 28 17:59:47 CET 2012
On 28/12/12 8:53 AM, Paul B Mahol wrote:
> On 12/28/12, Paul B Mahol <onemda at gmail.com> wrote:
>> On 12/27/12, James Almer <jamrial at gmail.com> wrote:
>>> Hello.
>>> The attached patch fixes ticket #2065 for me.
>>>
>>> Regards.
>>>
>>
>> lgtm, better than my patch.
>>
>
> Hmm, I think this does not work for files with multiple data chunks.
I didn't notice you posted a patch before mine, sorry.
Does the demuxer even support multiple data chunks properly?
It seems to me that it only uses the last one it finds, since it seeks to
its start offset at the end of wav_read_header and stores its end offset
in wav->data_end, discarding everything from previous data chunks.
The patch should in theory still work with such files, since wav->data_end
should still be <= than the file size, but i can't be sure since i don't
have any.
If you think it really wont work then we can drop this patch in favor of yours.
Regards.
More information about the ffmpeg-devel
mailing list