summaryrefslogtreecommitdiff
path: root/libguile/coop.c
diff options
context:
space:
mode:
authorMarius Vollmer <mvo@zagadka.de>2002-11-04 15:43:00 +0000
committerMarius Vollmer <mvo@zagadka.de>2002-11-04 15:43:00 +0000
commit79796da5b5fcfd88a4de33c4e28998795f83465a (patch)
tree6494e1cfc7df96f1c93951b292f50b67459bd99c /libguile/coop.c
parent1e5f92cef16158bf6333a5bb692b08458c9c0242 (diff)
downloadguile-79796da5b5fcfd88a4de33c4e28998795f83465a.tar.gz
(coop_next_runnable_thread): Removed, wich should have happened when
GUILE_ISELECT was hard-wired.
Diffstat (limited to 'libguile/coop.c')
-rw-r--r--libguile/coop.c36
1 files changed, 1 insertions, 35 deletions
diff --git a/libguile/coop.c b/libguile/coop.c
index 36653fabc..c1e3ba293 100644
--- a/libguile/coop.c
+++ b/libguile/coop.c
@@ -40,7 +40,7 @@
* If you do not wish that, delete this exception notice. */
-/* $Id: coop.c,v 1.33 2002-11-03 22:05:10 mvo Exp $ */
+/* $Id: coop.c,v 1.34 2002-11-04 15:43:00 mvo Exp $ */
/* Cooperative thread library, based on QuickThreads */
@@ -223,40 +223,6 @@ coop_init ()
#endif
}
-/* Return the next runnable thread. If no threads are currently runnable,
- and there are sleeping threads - wait until one wakes up. Otherwise,
- return NULL. */
-
-coop_t *
-coop_next_runnable_thread()
-{
- int sleepers;
- coop_t *t;
- time_t now;
-
- do {
- sleepers = 0;
- now = time(NULL);
-
- /* Check the sleeping queue */
- while ((t = coop_qget(&coop_global_sleepq)) != NULL)
- {
- sleepers++;
- if (t->wakeup_time <= now)
- coop_qput(&coop_global_runq, t);
- else
- coop_qput(&coop_tmp_queue, t);
- }
- while ((t = coop_qget(&coop_tmp_queue)) != NULL)
- coop_qput(&coop_global_sleepq, t);
-
- t = coop_qget (&coop_global_runq);
-
- } while ((t == NULL) && (sleepers > 0));
-
- return t;
-}
-
void
coop_start()
{