file *sync; char temp[10];// filled by some data later and passed as argument inside the func criticalSection cs; void TH1(void *param)// how this thread recive dataOfFunc() with arguments { enterCriticalSection(&cs); dataOfFunc(sync,tempArray); Leave Critical Section(&cs); } void main { initializeCriticalSection(&cs); beginThread(TH1,0,---------); // here i want to know how to pass function nameand its parameterinside beginthread third variable enterCriticalSection dataOfFunc(sync,tempArray); Leave Critical Section (&cs) } void dataOfFunc(File *sync ,char [])// function which is to be called in threads { // all code to perform operation }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)