cpp thread crash

记一个问题

所有关联有效线程的std::thread在析构前都要被join或者被detach.

std::thread thread_lloyd(&pccvt::PCCVTOptimizer::lloyd, &m_pccvt, value);
thread_lloyd.detach();

Leave a Reply

Your email address will not be published. Required fields are marked *