I have this method to test if I successfully get ROT:
void func()
{
IRunningObjectTable *rot;
qDebug() << GetRunningObjectTable(0, &rot);
}
Everything's fine from main thread but not in a separate one:
func(); // qDebug prints S_OK (0)
QFuture<void> future = QtConcurrent::run(func); // qDebug prints E_UNEXPECTED (0x8000FFFF)
Compiling with MinGW 5.3.0 32bits.
I don't get why would it be different from the main thread than an other.
Help would be appreciated.