討論串[問題] 請問pthread的問題
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓5(5推 0噓 9→)留言14則,0人參與, 最新作者lackofblack (...)時間16年前 (2009/04/27 13:58), 編輯資訊
1
0
0
內容預覽:
void *func(void *). {. .... }. while(...). {. pthread_t thrd;. pthread_create(thrd, NULL, func, NULL);. .... .... pthread_cancel(thrd);. }. ----------
(還有44個字)

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者cole945 (躂躂..)時間16年前 (2009/04/27 15:01), 編輯資訊
0
0
0
內容預覽:
與其說 create thead 的數目有上限,. 應該說, 你同時能 create thread 的數目有上限... 你這裡雖然用了 pthread_cancel,. 但 pthread 預設的 cancel 方式是 PTHREAD_CANCEL_DEFERRED ,. 也就是說, 你的 thre
(還有384個字)
首頁
上一頁
1
下一頁
尾頁