nill out thread private storage pointer just after making it a task variable in
the new thread so that it will not point at the other thread's task variable
This commit is contained in:
1 parent
a62dcb8215
commit
086b19d059
1 file changed
+1
@@ -107,6 +107,7 @@ static void createFunction(THREADFUNC func, void *parm)
|
||||
int tid = taskIdSelf();
|
||||
|
||||
taskVarAdd(tid,(int *)&papTSD);
|
||||
papTSD = 0;
|
||||
(*func)(parm);
|
||||
taskVarDelete(tid,(int *)&papTSD);
|
||||
free(papTSD);
|
||||
|
||||
Reference in new issue
Block a user