Browse Source

lavf/wavenc: check for a single stream.

Fix trac ticket #3110.
tags/n2.2-rc1
Nicolas George 11 years ago
parent
commit
eeb975f5cd
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      libavformat/wavenc.c

+ 5
- 0
libavformat/wavenc.c View File

@@ -116,6 +116,11 @@ static int wav_write_header(AVFormatContext *s)
AVIOContext *pb = s->pb;
int64_t fmt;

if (s->nb_streams != 1) {
av_log(s, AV_LOG_ERROR, "WAVE files have exactly one stream\n");
return AVERROR(EINVAL);
}

if (wav->rf64 == RF64_ALWAYS) {
ffio_wfourcc(pb, "RF64");
avio_wl32(pb, -1); /* RF64 chunk size: use size in ds64 */


Loading…
Cancel
Save