Waiting slots to be executed before quitting
问题 I've a thread that read datas class MyThread: QThread { ... } void MyThread::run () { uint8_t* buffer; // in my real code, it's a ring, so there is not read during write // ... while (true) { if (isInterruptionRequested()) return; USB_READ(buffer); emit newData(buffer); } } In my UI Class I have: connect(this, &UIClass::newData, m_thread, &MyThread::newData); // ... void newData(uint8_t* data) { // Process data } void UIClass::closeEvent(QCloseEvent *event) { disconnect(this, &UIClass: