diff options
author | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2010-04-24 20:46:54 +0300 |
---|---|---|
committer | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2010-04-25 22:48:10 +0300 |
commit | 05ae9dbd0dcc4fcce02a97011a46d89dab860021 (patch) | |
tree | f839629bcb07817af7b52f96fcd5d592b3b34c81 /command.c | |
parent | dd1760e697f38a13f05d2d8563598a2e6ed0a84f (diff) | |
download | mpv-05ae9dbd0dcc4fcce02a97011a46d89dab860021.tar.bz2 mpv-05ae9dbd0dcc4fcce02a97011a46d89dab860021.tar.xz |
Fix chapter handling with first chapter not at beginning of file
Before "-chapter 1" did nothing even if the first chapter didn't start
at the beginning of file. Fix it.
Before all chapter property commands (including chapter seek keys)
failed if the current playback position was before the start of the
first chapter. Now they'll work. Relative chapter seeks will go to the
first chapter (even if that's in the wrong direction for backward
seeks).
Diffstat (limited to 'command.c')
-rw-r--r-- | command.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -396,7 +396,7 @@ static int mp_property_chapter(m_option_t *prop, int action, void *arg, if (mpctx->demuxer) chapter = get_current_chapter(mpctx); - if (chapter < 0) + if (chapter < -1) return M_PROPERTY_UNAVAILABLE; switch (action) { |