Commit 3821632e authored by Paul B Mahol's avatar Paul B Mahol

smush: set audio packet duration

Signed-off-by: 's avatarPaul B Mahol <onemda@gmail.com>
parent 1bb30d02
......@@ -207,10 +207,15 @@ static int smush_read_packet(AVFormatContext *ctx, AVPacket *pkt)
done = 1;
break;
case MKBETAG('W', 'a', 'v', 'e'):
if (size < 13)
return AVERROR_INVALIDDATA;
if (av_get_packet(pb, pkt, size) < 0)
return AVERROR(EIO);
pkt->stream_index = smush->audio_stream_index;
pkt->duration = AV_RB32(pkt->data);
if (pkt->duration == 0xFFFFFFFFu)
pkt->duration = AV_RB32(pkt->data + 8);
done = 1;
break;
default:
......
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