summaryrefslogtreecommitdiffstats
path: root/input
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-04-26 16:56:50 +0200
committerwm4 <wm4@nowhere>2014-04-26 16:58:23 +0200
commitd44dd30ac7c6b3928d8aef00eb4ecf755b31997a (patch)
tree000930a255b3191c55282902f860ef1cbf6431c5 /input
parent75d7d87e1b43424572a5a441a9132e49d82ce8c6 (diff)
downloadmpv-d44dd30ac7c6b3928d8aef00eb4ecf755b31997a.tar.bz2
mpv-d44dd30ac7c6b3928d8aef00eb4ecf755b31997a.tar.xz
input: fix inverted condition
pthread_equal() returns 0 if the threads are not the same, and somehow I got that wrong. The worst is that I actually explicitly checked the manpage when I wrote this code.
Diffstat (limited to 'input')
-rw-r--r--input/input.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/input/input.c b/input/input.c
index 2671256270..63526138e7 100644
--- a/input/input.c
+++ b/input/input.c
@@ -1653,7 +1653,7 @@ bool mp_input_check_interrupt(struct input_ctx *ictx)
input_lock(ictx);
bool res = test_abort(ictx);
if (!res && ictx->mainthread_set &&
- pthread_equal(ictx->mainthread, pthread_self()) == 0)
+ pthread_equal(ictx->mainthread, pthread_self()))
{
read_events(ictx, 0);
}