76 + // check if the player exists ( the application still running )
77 + if (!m_player) {
78 + return QImage();
79 + }
80 +
81 + m_mutex.lock();
Why there is the need to check for m_player before and after locking the mutex? Wouldn't it be enough to check for the player just after the mutex acquires the lock?
76 + // check if the player exists ( the application still running )
77 + if (!m_player) {
78 + return QImage();
79 + }
80 +
81 + m_mutex.lock();
Why there is the need to check for m_player before and after locking the mutex? Wouldn't it be enough to check for the player just after the mutex acquires the lock?