Why am I getting runtime errors, with Sockets (TCP/Web) when moved to another thread? Is `QObject::moveToThread()` a synchronous call? [duplicate]
问题 This question already has answers here : How do I execute QTcpSocket in a different thread? (4 answers) Closed 15 days ago . I am moving some sockets from main thread to worker thread and processing readyRead() , close() , write() etc. on the new thread. Rarely I see below dangerous warning: "QSocketNotifier: Socket notifiers cannot be enabled or disabled from another thread" Usually the execution after this warning results in undefined behaviour (crash / uncaught exception / normal). Have