Remove if (f->valid_bits < 0) return 0; on line 1603

I propose to remove this line because  f->valid_bits will never be less than zero since, in the while loop, you're adding 8 to it. Therefore, it will always evaluate to false. This is to help remove redundant code.
This commit is contained in:
wph612 2020-03-24 19:47:18 -04:00 committed by GitHub
parent f54acd4e13
commit fcd0a0bfaa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -1600,7 +1600,7 @@ static uint32 get_bits(vorb *f, int n)
f->valid_bits += 8;
}
}
if (f->valid_bits < 0) return 0;
z = f->acc & ((1 << n)-1);
f->acc >>= n;
f->valid_bits -= n;