QT QSocketNotifier: Socket notifiers cannot be enabled or disabled from another thread
-
It would rather be: do your blocking input in one thread and manage your network in another one.
-
It would rather be: do your blocking input in one thread and manage your network in another one.
-
You might be interested by this small example for reading std using Qt.
-
You might be interested by this small example for reading std using Qt.
wrote on 27 Apr 2018, 11:22 last edited by@SGaist thanks very much
I tried this way too, but here I must pass the socketDescriptor as a parameter in QSocketNotifier. Its a bit confusing on client side how we can get socketDescriptor as in my knowledge we can only get socketdescriptor at serverside because of its Incommingconnection(). now, One more thing....Is it possible to get a warning of socket Notifier because reading and writing functions are being called at the same time ??
-
The socket notifier was only for stdin. As for your client side network connection, do everything in your dedicated worker object.
21/25