CreateThread() executes ONLY once ... ?
Hello. I am working on a multi-threaded application using sockets, and I am using the CreateThread() function. BTW, I am using MS Visual C++ 6.0 Standard on a Windows 98 machine, using MFC for this app. Anyhow, I added a 'AfxMessageBox("Test");' to my thread function, and it is only called once, and then ends the thread. I think it has something to do with WaitFor(Single/Multiple)Object(s), but I tried those. It says the thread's handle needs to have the "SYNCHRONIZE" right, but I don't know how to do that. If you can, please offer any help.