From: Takashi Iwai Date: Tue, 16 Sep 2014 14:36:44 +0000 (+0200) Subject: speaker-test: Add missing draining at the end X-Git-Tag: v1.0.29~14 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=f58ce3619de0612a6402c38f1cd81fb821818b60;p=alsa-utils.git speaker-test: Add missing draining at the end Without the call of snd_pcm_drain() the pending data on the buffer might be discarded, which results in the abort of playback sound in the middle. Let's fix it. Reported-and-tested-by: Jarkko Nikula Signed-off-by: Takashi Iwai --- diff --git a/speaker-test/speaker-test.c b/speaker-test/speaker-test.c index 61396f2..362efa7 100644 --- a/speaker-test/speaker-test.c +++ b/speaker-test/speaker-test.c @@ -1307,6 +1307,7 @@ int main(int argc, char *argv[]) { } } + snd_pcm_drain(handle); free(frames); #ifdef CONFIG_SUPPORT_CHMAP