From: Andre Noll Date: Sat, 7 Nov 2009 13:05:18 +0000 (+0100) Subject: fecdec_filter: Avoid potentially expensive pointer subtraction. X-Git-Tag: v0.4.0~1^2^2~1 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=0dd69d3988a677aeb8d0d3aea8364c664ac35fb9 fecdec_filter: Avoid potentially expensive pointer subtraction. Found by sparse. --- diff --git a/fecdec_filter.c b/fecdec_filter.c index a393a230..41db249e 100644 --- a/fecdec_filter.c +++ b/fecdec_filter.c @@ -102,7 +102,7 @@ struct private_fecdec_data { /** Iterate over all fecdec groups. */ #define FOR_EACH_FECDEC_GROUP(g, d) for (g = (d)->groups; \ - (g) - (d)->groups < NUM_FEC_GROUPS; (g)++) + (g) < (d)->groups + NUM_FEC_GROUPS; (g)++) static int group_complete(struct fecdec_group *fg) {