From e067fee29abb8c92e98e72dd6dc4eee9662f6def Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Wed, 16 Sep 2009 13:41:46 +0000 Subject: fixed cue bug git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1227 90c681e8-e032-0410-971d-27865f9a5e38 --- src/qmmp/soundcore.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/qmmp/soundcore.cpp b/src/qmmp/soundcore.cpp index 0b51adb15..c8881a9e1 100644 --- a/src/qmmp/soundcore.cpp +++ b/src/qmmp/soundcore.cpp @@ -228,9 +228,12 @@ QString SoundCore::metaData(Qmmp::MetaData key) bool SoundCore::decode() { qDebug("ready"); - if(!m_inputSource->ioDevice()->isOpen()) - m_inputSource->ioDevice()->open(QIODevice::ReadOnly); - disconnect(m_inputSource->ioDevice(), SIGNAL(readyRead()), this, SLOT(decode())); + if(m_inputSource->ioDevice()) + { + if(!m_inputSource->ioDevice()->isOpen()) + m_inputSource->ioDevice()->open(QIODevice::ReadOnly); + disconnect(m_inputSource->ioDevice(), SIGNAL(readyRead()), this, SLOT(decode())); + } if(!m_engine) { -- cgit v1.2.3-13-gbd6f