summaryrefslogtreecommitdiffstats
path: root/player/playloop.c
diff options
context:
space:
mode:
Diffstat (limited to 'player/playloop.c')
-rw-r--r--player/playloop.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/player/playloop.c b/player/playloop.c
index 8a0aba2ec8..22cc12f70d 100644
--- a/player/playloop.c
+++ b/player/playloop.c
@@ -451,7 +451,7 @@ int get_current_chapter(struct MPContext *mpctx)
double current_pts = get_current_time(mpctx);
int i;
for (i = 0; i < mpctx->num_chapters; i++)
- if (current_pts < mpctx->chapters[i].start)
+ if (current_pts < mpctx->chapters[i].pts)
break;
return MPMAX(mpctx->last_chapter_seek, i - 1);
}
@@ -490,7 +490,7 @@ double chapter_start_time(struct MPContext *mpctx, int chapter)
if (chapter == -1)
return get_start_time(mpctx);
if (chapter >= 0 && chapter < mpctx->num_chapters)
- return mpctx->chapters[chapter].start;
+ return mpctx->chapters[chapter].pts;
return MP_NOPTS_VALUE;
}