|
-
January 4th, 2005, 08:25 PM
#1
MFC Bug or My Bug
I've written a very simple MFC Dialog Program
A dialog contain a OK Button and a edit control
then i write the following code
UINT TestThread(LPVOID lpParam)
{
CSocket s;
s.Create(0,SOCK_DGRAM);
while (1) {
//...
Sleep(1000);
}
}
void CTestDialog::OnOK()
{
AfxSocketInit(NULL);
AfxBeginThread(TestThread,0);
}
when the thread start, all things seems well, but when i want to shift another input method in the edit box, the mainthread is hang~
What's the problem in my code .
Any advice will be appreciate
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|