avformat/thp: set duration for audio stream too
authorPaul B Mahol <onemda@gmail.com>
Sun, 25 Oct 2015 22:07:21 +0000 (23:07 +0100)
committerPaul B Mahol <onemda@gmail.com>
Mon, 26 Oct 2015 09:08:01 +0000 (10:08 +0100)
Signed-off-by: Paul B Mahol <onemda@gmail.com>
libavformat/thp.c

index 727fb50..5a748b0 100644 (file)
@@ -135,6 +135,7 @@ static int thp_read_header(AVFormatContext *s)
             st->codec->codec_tag = 0;  /* no fourcc */
             st->codec->channels    = avio_rb32(pb); /* numChannels.  */
             st->codec->sample_rate = avio_rb32(pb); /* Frequency.  */
+            st->duration           = avio_rb32(pb);
 
             avpriv_set_pts_info(st, 64, 1, st->codec->sample_rate);