Is it safe to for example do:
void AddTwo(int &num) { num +=2; } void ThreadProc(lpvoid arg) { AddTwo((int)arg); }
Would it be saf
The function itself is safe to call. It becomes dangerous if they're all trying to operate on the same variable.