From 0ec0c147ed32dd328489d3dc2833b13aa1fcd773 Mon Sep 17 00:00:00 2001 From: wm4 Date: Mon, 12 Feb 2018 19:00:38 +0100 Subject: audio: don't touch spdif frames in mp_aframe_clip_timestamps() It can't work for this type of format. --- audio/aframe.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'audio') diff --git a/audio/aframe.c b/audio/aframe.c index 9115cf67fd..cb5d412f98 100644 --- a/audio/aframe.c +++ b/audio/aframe.c @@ -441,12 +441,15 @@ double mp_aframe_duration(struct mp_aframe *f) // Clip the given frame to the given timestamp range. Adjusts the frame size // and timestamp. +// Refuses to change spdif frames. void mp_aframe_clip_timestamps(struct mp_aframe *f, double start, double end) { double f_end = mp_aframe_end_pts(f); double rate = mp_aframe_get_effective_rate(f); if (f_end == MP_NOPTS_VALUE) return; + if (af_fmt_is_spdif(mp_aframe_get_format(f))) + return; if (end != MP_NOPTS_VALUE) { if (f_end >= end) { if (f->pts >= end) { -- cgit v1.2.3