diff options
author | Zhentan Feng <spyfeng@gmail.com> | 2009-04-08 16:01:10 +0000 |
---|---|---|
committer | Carl Eugen Hoyos <cehoyos@rainbow.studorg.tuwien.ac.at> | 2009-04-08 16:01:10 +0000 |
commit | c81604f862a550bef5261680cfdc48deb6fce046 (patch) | |
tree | d0e0a7c05d68dd70d142f38295adc2a97bbad3bc /libavformat/riff.c | |
parent | 2851d2253f9ecece3e620832a16c54888dea18a5 (diff) | |
download | ffmpeg-c81604f862a550bef5261680cfdc48deb6fce046.tar.gz |
Reduce code duplication.
Patch by Zhentan Feng, spyfeng gmail
Originally committed as revision 18377 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/riff.c')
-rw-r--r-- | libavformat/riff.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/libavformat/riff.c b/libavformat/riff.c index aa33c097c1..3665176f47 100644 --- a/libavformat/riff.c +++ b/libavformat/riff.c @@ -352,10 +352,7 @@ int put_wav_header(ByteIOContext *pb, AVCodecContext *enc) bytestream_put_le16(&riff_extradata, 16); /* fwHeadFlags */ bytestream_put_le32(&riff_extradata, 0); /* dwPTSLow */ bytestream_put_le32(&riff_extradata, 0); /* dwPTSHigh */ - } else if (enc->codec_id == CODEC_ID_GSM_MS) { - hdrsize += 2; - bytestream_put_le16(&riff_extradata, enc->frame_size); /* wSamplesPerBlock */ - } else if (enc->codec_id == CODEC_ID_ADPCM_IMA_WAV) { + } else if (enc->codec_id == CODEC_ID_GSM_MS || enc->codec_id == CODEC_ID_ADPCM_IMA_WAV) { hdrsize += 2; bytestream_put_le16(&riff_extradata, enc->frame_size); /* wSamplesPerBlock */ } else if(enc->extradata_size){ |