Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
*/
void QLibrary::setFileNameAndVersion(const QString &fileName, const QString &version)
{
- QMutexLocker locker(qGlobalLibraryMutex());
// if the library path is not the same it may very well be library with different symbols
const QString librarymatch = qt_find_library(fileName, version);
+ QMutexLocker locker(qGlobalLibraryMutex());
QLibraryCleanup* loadedlibraries = qGlobalLibraryList();
for (int i = 0; i < loadedlibraries->size(); i++) {
QLibraryPrivate* loadedlibrary = loadedlibraries->at(i);
*/
QObject *QPluginLoader::instance()
{
- if (!d_ptr->loadPlugin()) {
+ if (!d_ptr->isPlugin() || !d_ptr->loadPlugin()) {
return nullptr;
}
if (!d_ptr->inst && d_ptr->instance)