summaryrefslogtreecommitdiffstats
path: root/mpvcore/mplayer.c
diff options
context:
space:
mode:
authorPhilip Sequeira <phsequei@gmail.com>2013-10-08 23:51:00 -0400
committerwm4 <wm4@nowhere>2013-10-12 18:57:02 +0200
commit7ce464bef9c8ef13ca8343f24d126c468086a60f (patch)
tree30d7e1a6efd40da9b3e00f50ca23720d396aafa9 /mpvcore/mplayer.c
parentd1c473bc258b863f8619ffaf7d70112136ef1039 (diff)
downloadmpv-7ce464bef9c8ef13ca8343f24d126c468086a60f.tar.bz2
mpv-7ce464bef9c8ef13ca8343f24d126c468086a60f.tar.xz
options: --loop=N means playback N times, not N+1 times
The argument or this change is that --loop should set how often the file is played, not the number of additional repeats. Based on pull request 277, with additions to the manpage and removal of "--loop=0". Signed-off-by: wm4 <wm4@nowhere>
Diffstat (limited to 'mpvcore/mplayer.c')
-rw-r--r--mpvcore/mplayer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mpvcore/mplayer.c b/mpvcore/mplayer.c
index 7de8ff2abf..4d745cf107 100644
--- a/mpvcore/mplayer.c
+++ b/mpvcore/mplayer.c
@@ -4736,9 +4736,9 @@ struct playlist_entry *mp_next_file(struct MPContext *mpctx, int direction,
if (mpctx->opts->shuffle)
playlist_shuffle(mpctx->playlist);
next = mpctx->playlist->first;
- if (next && mpctx->opts->loop_times > 0) {
+ if (next && mpctx->opts->loop_times > 1) {
mpctx->opts->loop_times--;
- if (mpctx->opts->loop_times == 0)
+ if (mpctx->opts->loop_times == 1)
mpctx->opts->loop_times = -1;
}
} else {