pike.git/
src/
threads.c
Branch:
Tag:
Non-build tags
All tags
No tags
1998-07-17
1998-07-17 22:37:11 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>
939b18baae58e987992829a517fce93a7c44282a (
11
lines) (+
10
/-
1
)
[
Show
|
Annotate
]
Branch:
7.9
more debug
Rev: src/program.c:1.98
Rev: src/threads.c:1.79
1:
#include "global.h"
-
RCSID("$Id: threads.c,v 1.
78
1998/07/17
13
:
28
:
25
grubba
Exp $");
+
RCSID("$Id: threads.c,v 1.
79
1998/07/17
22
:
37
:
11
hubbe
Exp $");
int num_threads = 1; int threads_disabled = 0;
326:
{ struct thread_state *s = (struct thread_state *)o->storage; unsigned INT32 h = thread_table_hash(&s->id);
+
#ifdef DEBUG
+
if(h>=THREAD_TABLE_SIZE)
+
fatal("thread_table_hash failed miserably!\n");
+
#endif
mt_lock( & thread_table_lock ); if((s->hashlink = thread_table_chains[h]) != NULL) s->hashlink->backlink = &s->hashlink;
348:
{ unsigned INT32 h = thread_table_hash(&tid); struct thread_state *s = NULL;
+
#ifdef DEBUG
+
if(h>=THREAD_TABLE_SIZE)
+
fatal("thread_table_hash failed miserably!\n");
+
#endif
mt_lock( & thread_table_lock ); if(thread_table_chains[h] == NULL) {