QLibrary.load freezes application
-
Hey guys,
I have a problem with one of my applications.
I'm loading a dll with QLibrary. While I'm in my debug-configuration everything is fine, but as soon as I'm on release QLibrary.load never finishes.
When I restart my application several times, suddenly it works but only 1 out of 15 trials...Any idea what could be the reason for it?
I'm using the same dll in several applications without problems.CU
mtsOS: windows 64bit
Qt: 5.8.0 -
Hey guys,
I have a problem with one of my applications.
I'm loading a dll with QLibrary. While I'm in my debug-configuration everything is fine, but as soon as I'm on release QLibrary.load never finishes.
When I restart my application several times, suddenly it works but only 1 out of 15 trials...Any idea what could be the reason for it?
I'm using the same dll in several applications without problems.CU
mtsOS: windows 64bit
Qt: 5.8.0 -
bool LoadAHEDnetLib(QString pathAHEDnetLib = "") { QFile file(pathAHEDnetLib); if ((pathAHEDnetLib == "") || (!file.exists())){ _ahedLib = new QLibrary("libAHEDnet.dll"); } else _ahedLib = new QLibrary(pathAHEDnetLib); qDebug() << "Load AHEDnet.dll"; if ((_ahedLib == NULL) || !_ahedLib->load()) <<<THIS IS THE LINE WHERE IT FREEZES return false; <<<< THIS LINE IS NEVER REACHED qDebug() << "Load AHEDnet.dll DONE"; <<<< THIS LINE IS NEVER REACHED ... }
Quite simple...
It's not returning failed or anything, it's just dead-locked. -
bool LoadAHEDnetLib(QString pathAHEDnetLib = "") { QFile file(pathAHEDnetLib); if ((pathAHEDnetLib == "") || (!file.exists())){ _ahedLib = new QLibrary("libAHEDnet.dll"); } else _ahedLib = new QLibrary(pathAHEDnetLib); qDebug() << "Load AHEDnet.dll"; if ((_ahedLib == NULL) || !_ahedLib->load()) <<<THIS IS THE LINE WHERE IT FREEZES return false; <<<< THIS LINE IS NEVER REACHED qDebug() << "Load AHEDnet.dll DONE"; <<<< THIS LINE IS NEVER REACHED ... }
Quite simple...
It's not returning failed or anything, it's just dead-locked.