resindvd: guard against overflow in menu subtitle streams
authorVincent Penquerc'h <vincent.penquerch@collabora.co.uk>
Tue, 8 Apr 2014 13:19:29 +0000 (14:19 +0100)
committerVincent Penquerc'h <vincent.penquerch@collabora.co.uk>
Tue, 8 Apr 2014 13:21:53 +0000 (14:21 +0100)
commit380f95ea0159b2f01b8c7f4a031d4cc5a860f714
treef1ea5cee374f0191339e674e53bfb9b7d0e1e63e
parent4898a51afe0dae7f6f3748c7ac2987edbc9e8446
resindvd: guard against overflow in menu subtitle streams

There is space for a single subtitle stream, but up to 255
may be used based on a uint8_t value in a struct, which may
or may not be read from the (untrusted) data.
A comment in ifo_types.h says this value is either 0 or 1, so
we can ensure this here without drawbacks.

Coverity 1139586
ext/resindvd/resindvdsrc.c