[問題] linux c裡有可以kill thread的function嗎?
請問一下各位
在linux c裡有可以kill thread的function嗎?
如下~
有類似kill_thread(thread_id)????的function嗎?
感謝!!!
-----------------------------------------
void Test()
{
while(1)
printf("123\n");
}
void main()
{
int conut = 0;
pthread_create(&thread_id, NULL, &Test, NULL);
if (conut < 10)
sleep(5);
//kill_thread(thread_id)????
}
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 220.133.37.155
推
08/22 14:25, , 1F
08/22 14:25, 1F
→
09/04 18:40, , 2F
09/04 18:40, 2F
LinuxDev 近期熱門文章
PTT數位生活區 即時熱門文章