diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2012-03-02 07:58:56 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2012-03-02 07:58:56 +0000 |
| commit | 1e1097d7d0ecbc5c48a2cc2ccfd3d4c262013da0 (patch) | |
| tree | 2bcc121d806d58e6f2d6c3f9742668c5b3145de5 | |
| parent | 6b940c049832cf3d93586eff0c678d96a9783135 (diff) | |
| download | qmmp-1e1097d7d0ecbc5c48a2cc2ccfd3d4c262013da0.tar.gz qmmp-1e1097d7d0ecbc5c48a2cc2ccfd3d4c262013da0.tar.bz2 qmmp-1e1097d7d0ecbc5c48a2cc2ccfd3d4c262013da0.zip | |
fixed QIODevice warning
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@2668 90c681e8-e032-0410-971d-27865f9a5e38
| -rw-r--r-- | src/qmmp/soundcore.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/qmmp/soundcore.cpp b/src/qmmp/soundcore.cpp index 4dccb3c1c..856f035e5 100644 --- a/src/qmmp/soundcore.cpp +++ b/src/qmmp/soundcore.cpp @@ -232,7 +232,7 @@ void SoundCore::startNextSource() InputSource *s = m_sources.dequeue(); m_url = s->url(); - if(s->ioDevice() && !s->ioDevice()->open(QIODevice::ReadOnly)) + if(s->ioDevice() && !s->ioDevice()->isOpen() && !s->ioDevice()->open(QIODevice::ReadOnly)) { qWarning("SoundCore: input error: %s", qPrintable(s->ioDevice()->errorString())); m_url.clear(); @@ -272,9 +272,7 @@ void SoundCore::startNextSource() } else { - m_sources.prepend(s); //try for next engine - if(s->ioDevice()) - s->ioDevice()->close(); + m_sources.prepend(s); //try next engine m_nextState = ANOTHER_ENGINE; if(state() == Qmmp::Stopped || state() == Qmmp::Buffering) { |
