diff --git a/C/init.c b/C/init.c index 675cf5988..8b6237043 100755 --- a/C/init.c +++ b/C/init.c @@ -1135,7 +1135,8 @@ InitInvisibleAtoms(void) } #ifdef THREADS -InitThreadHandle(wid) +static void +InitThreadHandle(int wid) { FOREIGN_ThreadHandle(wid).in_use = FALSE; FOREIGN_ThreadHandle(wid).zombie = FALSE; diff --git a/H/Yap.h b/H/Yap.h index 11997c64b..5420215b9 100755 --- a/H/Yap.h +++ b/H/Yap.h @@ -276,7 +276,7 @@ extern char Yap_Option[20]; #endif #endif /* !IN_SECOND_QUADRANT */ -/* #define RANDOMIZE_START_ADDRESS 1*/ +/* #define RANDOMIZE_START_ADDRESS 1 */ #ifdef USE_SYSTEM_MALLOC #define HEAP_INIT_BASE 0L diff --git a/H/iglobals.h b/H/iglobals.h index 8bdee9d02..4b3132ddc 100644 --- a/H/iglobals.h +++ b/H/iglobals.h @@ -119,7 +119,7 @@ static void InitWorker(int wid) { #endif FOREIGN_WL(wid)->conttop0 = NULL; FOREIGN_WL(wid)->conttop = NULL; - FOREIGN_WL(wid)->disc_trail_entries = NULL; + FOREIGN_WL(wid)->disc_trail_entries = 0; FOREIGN_WL(wid)->Gc_ma_h_top = NULL; FOREIGN_WL(wid)->Gc_ma_h_list = NULL; @@ -151,7 +151,7 @@ static void InitWorker(int wid) { #endif #ifdef THREADS - InitThreadHandle; + InitThreadHandle(wid); #define FOREIGN_ThreadHandle(wid) (Yap_WLocal[(wid)].thread_handle) #define MY_ThreadHandle (Yap_WLocal[worker_id].thread_handle) #endif diff --git a/misc/GLOBALS b/misc/GLOBALS index 8c044f889..360412edc 100644 --- a/misc/GLOBALS +++ b/misc/GLOBALS @@ -127,7 +127,7 @@ Term *new_tr new_TR =NULL #endif struct gc_mark_continuation* conttop0 cont_top0 =NULL struct gc_mark_continuation* conttop cont_top =NULL -int disc_trail_entries discard_trail_entries =NULL +int disc_trail_entries discard_trail_entries =0 gc_ma_hash_entry Gc_ma_hash_table[GC_MAVARS_HASH_SIZE] gc_ma_hash_table void gc_ma_hash_entry* Gc_ma_h_top gc_ma_h_top =NULL gc_ma_hash_entry* Gc_ma_h_list gc_ma_h_list =NULL @@ -167,7 +167,7 @@ struct worker worker WORKER void #endif #ifdef THREADS -struct thandle thread_handle ThreadHandle InitThreadHandle +struct thandle thread_handle ThreadHandle InitThreadHandle(wid) #define FOREIGN_ThreadHandle(wid) (Yap_WLocal[(wid)].thread_handle) #define MY_ThreadHandle (Yap_WLocal[worker_id].thread_handle) #endif