diff options
author | wm4 <wm4@nowhere> | 2018-05-12 16:51:53 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2018-05-24 19:56:34 +0200 |
commit | ce1f5e78c2b10e24c78d7ee65d7196093709b8ce (patch) | |
tree | 101b19e7372368e4f900234262a55d71380835c2 /player/main.c | |
parent | 7f91e2684e8600c45512e36f03aadff0b825a1b0 (diff) | |
download | mpv-ce1f5e78c2b10e24c78d7ee65d7196093709b8ce.tar.bz2 mpv-ce1f5e78c2b10e24c78d7ee65d7196093709b8ce.tar.xz |
player: rename "lock" to "abort_lock"
If a struct as large as MPContext contains a field named "lock", it
creates the impression that it is the primary lock for MPContext. This
is wrong, the lock just protects a single field.
Diffstat (limited to 'player/main.c')
-rw-r--r-- | player/main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/player/main.c b/player/main.c index bc14bbce1c..d744c9cf12 100644 --- a/player/main.c +++ b/player/main.c @@ -189,7 +189,7 @@ void mp_destroy(struct MPContext *mpctx) uninit_libav(mpctx->global); mp_msg_uninit(mpctx->global); - pthread_mutex_destroy(&mpctx->lock); + pthread_mutex_destroy(&mpctx->abort_lock); talloc_free(mpctx); } @@ -283,7 +283,7 @@ struct MPContext *mp_create(void) .thread_pool = mp_thread_pool_create(mpctx, 0, 1, 30), }; - pthread_mutex_init(&mpctx->lock, NULL); + pthread_mutex_init(&mpctx->abort_lock, NULL); mpctx->global = talloc_zero(mpctx, struct mpv_global); |