pthread_cancel和pthread_exit有什么区别啊

huanghuanghuang 2005-03-09 09:03:53
rt
...全文
1446 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
tengulre 2005-03-10
  • 打赏
  • 举报
回复
up
core 2005-03-10
  • 打赏
  • 举报
回复 2
cancel结束另外一个进程
exit结束自己
blankman 2005-03-10
  • 打赏
  • 举报
回复
#include <pthread.h>

int pthread_cancel(pthread_t thread);

pthread_cancel sends a cancellation request to the thread denoted by the thread argument.

------------------------------------------------

#include <pthread.h>

void pthread_exit(void *retval);

pthread_exit terminates the execution of the calling thread.



understand?
huanghuanghuang 2005-03-10
  • 打赏
  • 举报
回复
up

23,131

社区成员

发帖
与我相关
我的任务
社区描述
Linux/Unix社区 应用程序开发区
社区管理员
  • 应用程序开发区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧