Found-by: <jdarnley>
Tested-by: James Darnley <james.darnley@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 181435a4de6e38e0a15ddaf16de9a157ef41cb18)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
... | ... |
@@ -57,8 +57,8 @@ static av_always_inline void RENAME(interleave)(TYPE *dst, TYPE *src0, TYPE *src |
57 | 57 |
{ |
58 | 58 |
int i; |
59 | 59 |
for (i = 0; i < w2; i++) { |
60 |
- dst[2*i ] = (src0[i] + (unsigned)add) >> shift; |
|
61 |
- dst[2*i+1] = (src1[i] + (unsigned)add) >> shift; |
|
60 |
+ dst[2*i ] = ((int)(src0[i] + (unsigned)add)) >> shift; |
|
61 |
+ dst[2*i+1] = ((int)(src1[i] + (unsigned)add)) >> shift; |
|
62 | 62 |
} |
63 | 63 |
} |
64 | 64 |
|