]> git.alsa-project.org Git - alsa-utils.git/commitdiff
- splitted pcm channels in two different devices to handle mmap correctly
authorAbramo Bagnara <abramo@alsa-project.org>
Sat, 8 Jan 2000 20:11:40 +0000 (20:11 +0000)
committerAbramo Bagnara <abramo@alsa-project.org>
Sat, 8 Jan 2000 20:11:40 +0000 (20:11 +0000)
- 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

index 1f9960f5276560b46a380250e0b56afeb14d36b1..ecf0a8ff8ca527aff2749f67be0642eb3c6fb1b7 100644 (file)
@@ -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);