From 8344e31ce65edabe91d6a0ed3094c8fb18947344 Mon Sep 17 00:00:00 2001 From: Abramo Bagnara Date: Sat, 8 Jan 2000 20:11:40 +0000 Subject: [PATCH] - splitted pcm channels in two different devices to handle mmap correctly - removed mmap control device - reordered pcm shared and not shared code - changed O_WRONLY oss pcm modifier in a more symmetric and elegant way - changed slightly control interface - added snd-debug-check - uniformed null pointer check - fixed a typo in linear plugin --- aplay/aplay.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/aplay/aplay.c b/aplay/aplay.c index 1f9960f..ecf0a8f 100644 --- a/aplay/aplay.c +++ b/aplay/aplay.c @@ -232,7 +232,7 @@ static void device_list(void) for (idx = 0; idx <= pcminfo.playback; idx++) { memset(&chninfo, 0, sizeof(chninfo)); chninfo.channel = SND_PCM_CHANNEL_PLAYBACK; - if ((err = snd_ctl_pcm_channel_info(handle, dev, idx, &chninfo)) < 0) { + if ((err = snd_ctl_pcm_channel_info(handle, dev, SND_PCM_CHANNEL_PLAYBACK, idx, &chninfo)) < 0) { printf("Error: control digital audio playback info (%i): %s\n", card, snd_strerror(err)); } else { printf(" Playback subdevice #%i: %s\n", idx, chninfo.subname); @@ -243,7 +243,7 @@ static void device_list(void) for (idx = 0; idx <= pcminfo.capture; idx++) { memset(&chninfo, 0, sizeof(chninfo)); chninfo.channel = SND_PCM_CHANNEL_CAPTURE; - if ((err = snd_ctl_pcm_channel_info(handle, dev, 0, &chninfo)) < 0) { + if ((err = snd_ctl_pcm_channel_info(handle, dev, SND_PCM_CHANNEL_CAPTURE, 0, &chninfo)) < 0) { printf("Error: control digital audio capture info (%i): %s\n", card, snd_strerror(err)); } else { printf(" Capture subdevice #%i: %s\n", idx, chninfo.subname);