(Solved)Weird behaviour of code
-
I have a small project, instant messaging client which uses QXmpp (working on win7, Qt 5.2.0). By now, everything was working fine. Today, I opened the project like any other day in qt creator and when compiling I got this:
QObject: Cannot create children for a parent that is in a different thread.
(Parent is MainWindow(0x45fc80), parent's thread is QThread(0x13e0d50), current thread is QThread(0x1601f60)
for this line:
@ client = new QXmppClient(this);@
It didnt happen before.
Also when I tried to connect to server I got this:
"Looking up server for domain 94.136.158.148"
QDnsLookup requires a QCoreApplication
which didnt hapen before eitherI found the reason, I somehow switched from debug mode to release which caused the problems, on debug mode it works.