1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avfilter/vf_elbg: Use unsigned for shifting into the top bit

Fixes: part of CID1355110 Overflowed constant

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 2af95b9214)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2024-07-08 00:45:45 +02:00
parent 0f843c76ee
commit b07d36fe69
No known key found for this signature in database
GPG Key ID: B18E8928B3948D64

View File

@ -193,7 +193,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
p0 = (uint8_t *)out->data[0];
for (i = 0; i < elbg->codebook_length; i++) {
const int al = elbg->use_alpha ? elbg->codebook[i*4+3] : 0xff;
const unsigned al = elbg->use_alpha ? elbg->codebook[i*4+3] : 0xff;
pal[i] = al << 24 |
(elbg->codebook[i*4+2] << 16) |
(elbg->codebook[i*4+1] << 8) |