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:36:56 +0000 (01:36 +0100)
commitd3835cb87714bece30e6ce748c9f11ca640859da
tree512ec64ad8154e298250e204e124dd6865a9b559
parentb06903e6c56d2e08c3b79f67a1e81e24e90c60ac
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
(cherry picked from commit e74cd2f4706f71da5e9205003c1d8263b54ed3fb)
libavformat/utils.c