mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-21 14:53:10 +00:00
check codec frame size directly and only for audio
Originally committed as revision 7280 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
2f5560ee49
commit
b596102e7e
@ -1518,10 +1518,10 @@ static int mov_write_header(AVFormatContext *s)
|
|||||||
default:
|
default:
|
||||||
track->sampleSize = (av_get_bits_per_sample(st->codec->codec_id) >> 3) * st->codec->channels;
|
track->sampleSize = (av_get_bits_per_sample(st->codec->codec_id) >> 3) * st->codec->channels;
|
||||||
}
|
}
|
||||||
}
|
if (!st->codec->frame_size) {
|
||||||
if (!track->sampleDuration) {
|
av_log(s, AV_LOG_ERROR, "track %d: codec frame size is not set\n", i);
|
||||||
av_log(s, AV_LOG_ERROR, "track %d: sample duration is not set\n", i);
|
return -1;
|
||||||
return -1;
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user