diff --git a/libavcodec/truemotion2.c b/libavcodec/truemotion2.c index 3443bbeda2..80a28a0ac6 100644 --- a/libavcodec/truemotion2.c +++ b/libavcodec/truemotion2.c @@ -606,7 +606,7 @@ static inline void tm2_null_res_block(TM2Context *ctx, AVFrame *pic, int bx, int ct = ctx->D[0] + ctx->D[1] + ctx->D[2] + ctx->D[3]; if (bx > 0) - left = last[-1] - ct; + left = last[-1] - (unsigned)ct; else left = 0; @@ -617,7 +617,7 @@ static inline void tm2_null_res_block(TM2Context *ctx, AVFrame *pic, int bx, int last[2] = right - (diff >> 2); last[3] = right; { - int tp = left; + unsigned tp = left; ctx->D[0] = (tp + (ct >> 2)) - left; left += ctx->D[0];