diff --git a/libavcodec/truemotion2.c b/libavcodec/truemotion2.c index 6cecbfd805..2d1fd0e41b 100644 --- a/libavcodec/truemotion2.c +++ b/libavcodec/truemotion2.c @@ -586,10 +586,10 @@ static inline void tm2_low_res_block(TM2Context *ctx, AVFrame *pic, int bx, int last[0] = (int)((unsigned)last[1] - ctx->D[0] - ctx->D[1] - ctx->D[2] - ctx->D[3])>> 1; last[2] = (int)((unsigned)last[1] + last[3]) >> 1; - t1 = ctx->D[0] + ctx->D[1]; + t1 = ctx->D[0] + (unsigned)ctx->D[1]; ctx->D[0] = t1 >> 1; ctx->D[1] = t1 - (t1 >> 1); - t2 = ctx->D[2] + ctx->D[3]; + t2 = ctx->D[2] + (unsigned)ctx->D[3]; ctx->D[2] = t2 >> 1; ctx->D[3] = t2 - (t2 >> 1);