summaryrefslogtreecommitdiffstats
path: root/player/misc.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2017-01-18 17:13:26 +0100
committerwm4 <wm4@nowhere>2017-01-18 17:52:05 +0100
commitc54c3b6991ac0273e6b7a42dc42c5103f87ff9f1 (patch)
tree1b543741e9bf171fa9a77fe90e4df9f62396284d /player/misc.c
parent04858c0b83fd6c1fc60519c2034e263d2e7c3977 (diff)
downloadmpv-c54c3b6991ac0273e6b7a42dc42c5103f87ff9f1.tar.bz2
mpv-c54c3b6991ac0273e6b7a42dc42c5103f87ff9f1.tar.xz
player: restructure cancel callback
As preparation for file prefetching, we basically have to get rid of using mpctx->playback_abort for the main demuxer (i.e. the thing that can be prefetched). It can't be changed on a running demuxer, and always using the same cancel handle would either mean aborting playback would also abort prefetching, or that playback can't be aborted anymore. Make this more flexible with some refactoring. Thi is a quite shitty solution if you ask me, but YOLO.
Diffstat (limited to 'player/misc.c')
-rw-r--r--player/misc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/player/misc.c b/player/misc.c
index eb4c1c031e..032342e84a 100644
--- a/player/misc.c
+++ b/player/misc.c
@@ -287,7 +287,7 @@ int mpctx_run_reentrant(struct MPContext *mpctx, void (*thread_fn)(void *arg),
mp_idle(mpctx);
if (mpctx->stop_play)
- mp_cancel_trigger(mpctx->playback_abort);
+ mp_abort_playback_async(mpctx);
pthread_mutex_lock(&args.mutex);
success |= args.done;