多线程笔记1

来源:互联网 发布:备份软件购买 编辑:程序博客网 时间:2024/03/28 20:14

1.如果不额外开设线程,消息循环和消息处理函数在一个线程里执行

2.ExitThread介绍线程本身:

void ExitThread(DWORD dwExitCode);

Parameters:

dwExitCode
[in] Exit code for the calling thread. Use the GetExitCodeThread function to retrieve a thread's exit code.

  TerminateThread在线程外结束线程:

BOOL TerminateThread(HANDLE hThread,DWORD dwExitCode);

   hThread :要结束的线程的句柄

   dwExitCode :同上

 

 

原创粉丝点击