comparison file.c @ 4688:0905585d48fd libavformat

Prevent (negative) overflow of rm->remaining_len. This evaluation really only has two possible outcomes: either len and rm->remaining_len are the same, in which case we care about the outcome and it is zero, or rm->remaining_len is currently not in use and we don't care about the outcome. In that case, len is positive and rm->remaining_len is zero, which leads to a negative result. This is confusing and could eventually lead to a sign-flip if we skip a lot of packets (unlikely, but still). Therefore, just always set it to zero.
author rbultje
date Mon, 09 Mar 2009 13:08:19 +0000
parents b34d9614b887
children dd9383951cb9
comparison
equal deleted inserted replaced
4687:0ff86cd08b4a 4688:0905585d48fd