]> git.alsa-project.org Git - alsa-lib.git/commitdiff
Fix start/stop of multi plugin
authorTakashi Iwai <tiwai@suse.de>
Mon, 12 Mar 2007 23:40:22 +0000 (00:40 +0100)
committerTakashi Iwai <tiwai@suse.de>
Mon, 12 Mar 2007 23:40:22 +0000 (00:40 +0100)
The start/stop of sync'ed stream of multi plugin.
This should make some JACK users with multiple devices happier.

src/pcm/pcm_multi.c

index 85403c6db06e256d8ae4b3e6be7318a2cb510550..68fcb3b55bdc367c78f710aca2d69893f06c547e 100644 (file)
@@ -621,7 +621,8 @@ static int snd_pcm_multi_link_fd(snd_pcm_t *pcm, int *fds, int count, int (**fai
                if (multi->slaves[i].linked)
                        snd_pcm_unlink(multi->slaves[i].pcm);
                fds[i] = _snd_pcm_link_descriptor(multi->slaves[i].pcm);
-               multi->slaves[i].linked = 1;
+               if (i > 0)
+                       multi->slaves[i].linked = 1;
        }
        *failed = snd_pcm_multi_link_fd_failed;
        return multi->slaves_count;