QTcpSocket windows vs android[SOLVED]
-
Hi,
I am aware of Qt-s way of dealing with sockets and threads, but I have managed to create app where I am using sockets in threads other than main thread. It works great on windows (no warnings, errors...).
BUT, when I build from same source for android (arm7) I get "Parent is QTcpSocket(0x5a356720), parent's thread is QThread(0x5a358d78), current thread is QThread(0x5d17f378)" error.
I know what error is saying, I am just wondering if anyone knows why I get this only on android and not on windows?
Thanks. -
Hi,
Because they do not share the same architecture, i.e. android is a linux based system.
Anyway, you can use socket from another thread, you need to construct it the correct way e.g. following the threaded fortune server example.
-
Thanks for the reply SGaist. I was desperately trying to avoid signals and slots in communication protocols, but I guess there's a first time for everything :).