Commit 2e752c7d authored by Andreas Cadhalpun's avatar Andreas Cadhalpun

ffmdec: change type of state and id to unsigned

This fixes ubsan runtime error: left shift by 8 places cannot be
represented in type 'int'
Reviewed-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
Signed-off-by: 's avatarAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
parent cccb0ffc
...@@ -68,7 +68,7 @@ static int ffm_is_avail_data(AVFormatContext *s, int size) ...@@ -68,7 +68,7 @@ static int ffm_is_avail_data(AVFormatContext *s, int size)
return AVERROR_INVALIDDATA; return AVERROR_INVALIDDATA;
} }
static int ffm_resync(AVFormatContext *s, int state) static int ffm_resync(AVFormatContext *s, uint32_t state)
{ {
av_log(s, AV_LOG_ERROR, "resyncing\n"); av_log(s, AV_LOG_ERROR, "resyncing\n");
while (state != PACKET_ID) { while (state != PACKET_ID) {
...@@ -87,7 +87,8 @@ static int ffm_read_data(AVFormatContext *s, ...@@ -87,7 +87,8 @@ static int ffm_read_data(AVFormatContext *s,
{ {
FFMContext *ffm = s->priv_data; FFMContext *ffm = s->priv_data;
AVIOContext *pb = s->pb; AVIOContext *pb = s->pb;
int len, fill_size, size1, frame_offset, id; int len, fill_size, size1, frame_offset;
uint32_t id;
int64_t last_pos = -1; int64_t last_pos = -1;
size1 = size; size1 = size;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment