From a7772ecabd99e13657fa840644a2aecfc02d6d44 Mon Sep 17 00:00:00 2001 From: deischen Date: Sat, 11 Nov 2000 22:20:36 +0000 Subject: Correct the logic for checking the emptiness of the waiting queue. This fixes a potential problem where the file descriptors would not be polled causing waiting threads to stay waiting. Doh! MFC candidate. --- lib/libkse/thread/thr_kern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/libkse') diff --git a/lib/libkse/thread/thr_kern.c b/lib/libkse/thread/thr_kern.c index 67844e1..4d92385 100644 --- a/lib/libkse/thread/thr_kern.c +++ b/lib/libkse/thread/thr_kern.c @@ -323,7 +323,7 @@ _thread_kern_scheduler(void) * Avoid polling file descriptors if there are none * waiting: */ - if (TAILQ_EMPTY(&_workq) == 0) { + if (TAILQ_EMPTY(&_workq) != 0) { } /* * Poll file descriptors only if a new scheduling signal -- cgit v1.1