• Michael Niedermayer's avatar
    avcodec/hevcpred_template: Fix integer overflows · 09ef98f1
    Michael Niedermayer authored
    signed integer overflow is undefined in C
    
    Fixes the following gcc warnings:
    In file included from libavcodec/hevcpred.c:27:0:
    libavcodec/hevcpred_template.c: In function ‘intra_pred_8’:
    libavcodec/hevcpred_template.c:302:9: warning: assuming signed overflow does not occur when assuming that (X - c) > X is always false [-Wstrict-overflow]
    In file included from libavcodec/hevcpred.c:31:0:
    libavcodec/hevcpred_template.c: In function ‘intra_pred_9’:
    libavcodec/hevcpred_template.c:302:9: warning: assuming signed overflow does not occur when assuming that (X - c) > X is always false [-Wstrict-overflow]
    In file included from libavcodec/hevcpred.c:35:0:
    libavcodec/hevcpred_template.c: In function ‘intra_pred_10’:
    libavcodec/hevcpred_template.c:302:9: warning: assuming signed overflow does not occur when assuming that (X - c) > X is always false [-Wstrict-overflow]
    Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
    09ef98f1
hevcpred_template.c 20.6 KB