Calling this function locks the mutex pointed by the argument. If the mutex is currently locked the
calling thread will wait until the mutex becomes available.
void thread_LockMutex(PMUTEX pMutex
){
Arguments:
pMutex should point to an initialized mutex variable of the type MUTEX