summaryrefslogtreecommitdiffstats
path: root/plugins/alsa
diff options
context:
space:
mode:
authorThierry Bultel <thierry.bultel@iot.bzh>2019-02-13 11:05:20 +0100
committerThierry Bultel <thierry.bultel@iot.bzh>2019-02-13 14:59:58 +0100
commit1c0ae808eb103ddae1a09186c3cdbb095685d658 (patch)
treef9ee3176105b13c0902ad610ff70ff70dc20c5e8 /plugins/alsa
parentd5cc09d1ef5c58bb8d34e3a47c391a10d8b48181 (diff)
alsa-utils-dump: added missing ending null char
For some reason, snd_pcm_hw_params_dump does not add a null char at the end of the dumped string. This made weird chars appear in the console Change-Id: I6f2895e730e9bbd0f78139505f9b9e68dd164f2e Signed-off-by: Thierry Bultel <thierry.bultel@iot.bzh>
Diffstat (limited to 'plugins/alsa')
-rw-r--r--plugins/alsa/alsa-utils-dump.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugins/alsa/alsa-utils-dump.c b/plugins/alsa/alsa-utils-dump.c
index 90e4842..676ab27 100644
--- a/plugins/alsa/alsa-utils-dump.c
+++ b/plugins/alsa/alsa-utils-dump.c
@@ -153,6 +153,7 @@ PUBLIC void AlsaDumpPcmParams(SoftMixerT *mixer, snd_pcm_hw_params_t *pcmHwParam
snd_output_buffer_open(&output);
snd_pcm_hw_params_dump(pcmHwParams, output);
+ snd_output_putc(output,'\0');
snd_output_buffer_string(output, &buffer);
AFB_API_DEBUG(mixer->api, "%s:\n--------------\n%s\n-------------",__func__, buffer);
snd_output_close(output);