Mercurial > libavcodec.hg
changeset 7137:186eb61a9860 libavcodec
Make it a little easier to spot that the code is not dealing only with
substream headers.
author | ramiro |
---|---|
date | Wed, 25 Jun 2008 12:08:39 +0000 |
parents | 7a73d76aaaa0 |
children | 1f85910c9ab2 |
files | mlp_parser.c |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mlp_parser.c Wed Jun 25 11:33:49 2008 +0000 +++ b/mlp_parser.c Wed Jun 25 12:08:39 2008 +0000 @@ -243,11 +243,11 @@ // Only check when this isn't a sync frame - syncs have a checksum. parity_bits = 0; - for (i = 0; i <= mp->num_substreams; i++) { + for (i = -1; i < mp->num_substreams; i++) { parity_bits ^= buf[p++]; parity_bits ^= buf[p++]; - if (i == 0 || buf[p-2] & 0x80) { + if (i < 0 || buf[p-2] & 0x80) { parity_bits ^= buf[p++]; parity_bits ^= buf[p++]; }