diff --git a/src/libtomahawk/infosystem/infosystem.cpp b/src/libtomahawk/infosystem/infosystem.cpp index 84a15bd67..42cc425c8 100644 --- a/src/libtomahawk/infosystem/infosystem.cpp +++ b/src/libtomahawk/infosystem/infosystem.cpp @@ -62,7 +62,7 @@ InfoSystem::InfoSystem(QObject *parent) m_infoSystemWorkerThreadController = new QThread( this ); m_worker = new InfoSystemWorker(); - m_worker->moveToThread( m_infoSystemWorkerThreadController ); + //m_worker->moveToThread( m_infoSystemWorkerThreadController ); m_infoSystemWorkerThreadController->start(); QMetaObject::invokeMethod( m_worker, "init", Qt::QueuedConnection ); diff --git a/src/libtomahawk/infosystem/infosystemworker.cpp b/src/libtomahawk/infosystem/infosystemworker.cpp index 763e34a65..83270f0ae 100644 --- a/src/libtomahawk/infosystem/infosystemworker.cpp +++ b/src/libtomahawk/infosystem/infosystemworker.cpp @@ -169,6 +169,13 @@ InfoSystemWorker::newNam() { qDebug() << Q_FUNC_INFO; + QNetworkAccessManager *oldNam = TomahawkUtils::nam(); + if ( oldNam && m_nam == oldNam ) + { + emit namChanged(); + return; + } + QNetworkAccessManager* newNam; #ifdef LIBLASTFM_FOUND newNam = new lastfm::NetworkAccessManager( this ); @@ -176,10 +183,8 @@ InfoSystemWorker::newNam() newNam = new QNetworkAccessManager( this ); #endif if ( m_nam ) - { delete m_nam; - } - QNetworkAccessManager *oldNam = TomahawkUtils::nam(); + if ( !oldNam ) { m_nam = newNam;