rm: prevent infinite loops for index parsing.
authorRonald S. Bultje <rsbultje@gmail.com>
Wed, 22 Feb 2012 19:33:24 +0000 (11:33 -0800)
committerRonald S. Bultje <rsbultje@gmail.com>
Wed, 22 Feb 2012 20:00:23 +0000 (12:00 -0800)
commitaac07a7a4c2c7a4a29cf6dbc88c1b9fdd191b99d
treee3adffb893f208b380c9225a1bda0dccf0abf022
parent1cd9a6154bc1ac1193c703cea980ed21c3e53792
rm: prevent infinite loops for index parsing.

Specifically, prevent jumping back in the file for the next index, since
this can lead to infinite loops where we jump between indexes referring
to each other, and don't read indexes that don't fit in the file.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
libavformat/rmdec.c