diff options
author | wm4 <wm4@nowhere> | 2013-10-02 20:43:13 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-10-02 20:43:13 +0200 |
commit | a4998e08effd7ddc536110580db5afb6aab5de7f (patch) | |
tree | 10eded47b07ab40fe9371505587b58c5b8c0608e /mpvcore | |
parent | a8240c1b5829999c6e242168239db916b9509373 (diff) | |
download | mpv-a4998e08effd7ddc536110580db5afb6aab5de7f.tar.bz2 mpv-a4998e08effd7ddc536110580db5afb6aab5de7f.tar.xz |
command: don't let "avsync" property print NOPTS value
Can happen when seeking in audio files with attached picture.
MP_NOPTS_VALUE doesn't really make sense outside of mpv internals, so
don't return it.
Diffstat (limited to 'mpvcore')
-rw-r--r-- | mpvcore/command.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/mpvcore/command.c b/mpvcore/command.c index a7dab8be8a..a18d5620a1 100644 --- a/mpvcore/command.c +++ b/mpvcore/command.c @@ -313,6 +313,8 @@ static int mp_property_avsync(m_option_t *prop, int action, void *arg, { if (!mpctx->sh_audio || !mpctx->sh_video) return M_PROPERTY_UNAVAILABLE; + if (mpctx->last_av_difference == MP_NOPTS_VALUE) + return M_PROPERTY_UNAVAILABLE; return m_property_double_ro(prop, action, arg, mpctx->last_av_difference); } |