lavf: compute probe buffer size more reliably.
authorNicolas George <nicolas.george@normalesup.org>
Tue, 4 Dec 2012 18:49:51 +0000 (19:49 +0100)
committerCarl Eugen Hoyos <cehoyos@ag.or.at>
Wed, 5 Dec 2012 00:31:50 +0000 (01:31 +0100)
commite74cd2f4706f71da5e9205003c1d8263b54ed3fb
tree5688f851f50fd5f61e1bbbd51a66d58d5223fca1
parent528700dd58abf654861bcfc32dd990bd0541baf5
lavf: compute probe buffer size more reliably.

The previous code computes the offset by reversing the growth
of the allocated buffer size: it is complex and did lead to
inconsistencies when the size limit is reached.

Fix trac ticket #1991.
(cherry picked from commit 03847eb8259291b4ff1bd840bd779d0699d71f96)

Conflicts:
libavformat/utils.c
libavformat/utils.c