Commit 4a055f91 authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit '1b5d065c'

* commit '1b5d065c':
  pmpdec: check that there is at least one audio packet.

Conflicts:
	libavformat/pmpdec.c

See: 8b1cd25cMerged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 3929c174 1b5d065c
......@@ -138,10 +138,12 @@ static int pmp_packet(AVFormatContext *s, AVPacket *pkt)
if (pmp->cur_stream == 0) {
int num_packets;
pmp->audio_packets = avio_r8(pb);
if (!pmp->audio_packets) {
avpriv_request_sample(s, "0 audio packets");
return AVERROR_PATCHWELCOME;
av_log(s, AV_LOG_ERROR, "No audio packets.\n");
return AVERROR_INVALIDDATA;
}
num_packets = (pmp->num_streams - 1) * pmp->audio_packets + 1;
avio_skip(pb, 8);
pmp->current_packet = 0;
......
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