summaryrefslogtreecommitdiffstats
path: root/src/multimedia/audio/qaudiooutput_mac_p.cpp
diff options
context:
space:
mode:
authorJustin McPherson <justin.mcpherson@nokia.com>2010-03-15 05:20:50 (GMT)
committerJustin McPherson <justin.mcpherson@nokia.com>2010-03-16 03:46:15 (GMT)
commit3f41524598f5b4795f0f6b279450daf792df927d (patch)
tree0126fbac6412aacf9b373ad9f9db0c8edc0ec607 /src/multimedia/audio/qaudiooutput_mac_p.cpp
parentdcae386d0387ebb28e6a15659844c4207ad50a63 (diff)
downloadQt-3f41524598f5b4795f0f6b279450daf792df927d.zip
Qt-3f41524598f5b4795f0f6b279450daf792df927d.tar.gz
Qt-3f41524598f5b4795f0f6b279450daf792df927d.tar.bz2
Make sure to check for a valid audioformat before open.
Reviewed-by:Dmytro Poplavskiy
Diffstat (limited to 'src/multimedia/audio/qaudiooutput_mac_p.cpp')
-rw-r--r--src/multimedia/audio/qaudiooutput_mac_p.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/multimedia/audio/qaudiooutput_mac_p.cpp b/src/multimedia/audio/qaudiooutput_mac_p.cpp
index 6f32257..b457fed 100644
--- a/src/multimedia/audio/qaudiooutput_mac_p.cpp
+++ b/src/multimedia/audio/qaudiooutput_mac_p.cpp
@@ -435,7 +435,7 @@ QIODevice* QAudioOutputPrivate::start(QIODevice* device)
{
QIODevice* op = device;
- if (!open()) {
+ if (!audioFormat.isValid() || !open()) {
stateCode = QAudio::StoppedState;
errorCode = QAudio::OpenError;
return audioIO;