diff options
Diffstat (limited to 'src/plugins/alsa')
-rw-r--r-- | src/plugins/alsa/qalsaaudioinput.cpp | 1 | ||||
-rw-r--r-- | src/plugins/alsa/qalsaaudiooutput.cpp | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/alsa/qalsaaudioinput.cpp b/src/plugins/alsa/qalsaaudioinput.cpp index d9c775148..5f7a788a6 100644 --- a/src/plugins/alsa/qalsaaudioinput.cpp +++ b/src/plugins/alsa/qalsaaudioinput.cpp @@ -701,6 +701,7 @@ qint64 QAlsaAudioInput::processedUSecs() const void QAlsaAudioInput::suspend() { if(deviceState == QAudio::ActiveState||resuming) { + snd_pcm_drain(handle); timer->stop(); deviceState = QAudio::SuspendedState; emit stateChanged(deviceState); diff --git a/src/plugins/alsa/qalsaaudiooutput.cpp b/src/plugins/alsa/qalsaaudiooutput.cpp index 5702cfc78..02681a4df 100644 --- a/src/plugins/alsa/qalsaaudiooutput.cpp +++ b/src/plugins/alsa/qalsaaudiooutput.cpp @@ -673,6 +673,7 @@ QAudioFormat QAlsaAudioOutput::format() const void QAlsaAudioOutput::suspend() { if(deviceState == QAudio::ActiveState || deviceState == QAudio::IdleState || resuming) { + snd_pcm_drain(handle); timer->stop(); deviceState = QAudio::SuspendedState; errorState = QAudio::NoError; |