From d3643636d2ec946fb9e23495fd629b94114ff8e8 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Sat, 19 Mar 2011 07:34:34 +0100 Subject: [PATCH] * Fixed Query crash. --- src/libtomahawk/query.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/libtomahawk/query.cpp b/src/libtomahawk/query.cpp index 750ccec3f..5c44a452a 100644 --- a/src/libtomahawk/query.cpp +++ b/src/libtomahawk/query.cpp @@ -173,18 +173,19 @@ Query::checkResults() // hook up signals, and check solved status foreach( const result_ptr& rp, m_results ) { - if ( rp->collection()->source()->isOnline() ) + if ( !rp->collection().isNull() && rp->collection()->source()->isOnline() ) { m_playable = true; - if ( !m_solved && rp->score() > 0.99 ) - { - m_solved = true; - becameSolved = true; - } if ( rp->score() > 0.99 ) { becameUnsolved = false; + + if ( !m_solved ) + { + m_solved = true; + becameSolved = true; + } } } }