avoid InitWorker twice for main thread
This commit is contained in:
parent
31b3eeaae6
commit
3345709bdb
4
C/init.c
4
C/init.c
@ -1205,9 +1205,11 @@ InitCodes(void)
|
|||||||
#include "ihstruct.h"
|
#include "ihstruct.h"
|
||||||
#if THREADS
|
#if THREADS
|
||||||
Yap_InitThread(0);
|
Yap_InitThread(0);
|
||||||
#endif
|
#endif /* THREADS */
|
||||||
InitGlobal();
|
InitGlobal();
|
||||||
|
#if !THREADS
|
||||||
InitWorker(0);
|
InitWorker(0);
|
||||||
|
#endif /* THREADS */
|
||||||
InitFirstWorkerThreadHandle();
|
InitFirstWorkerThreadHandle();
|
||||||
/* make sure no one else can use these two atoms */
|
/* make sure no one else can use these two atoms */
|
||||||
CurrentModule = 0;
|
CurrentModule = 0;
|
||||||
|
Reference in New Issue
Block a user