Update of /cvsroot/alsa/alsa-kernel/core/oss
In directory sc8-pr-cvs1:/tmp/cvs-serv22134

Modified Files:
        pcm_oss.c 
Log Message:
Fixed poll(POLLIN) - it should trigger capture

Index: pcm_oss.c
===================================================================
RCS file: /cvsroot/alsa/alsa-kernel/core/oss/pcm_oss.c,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- pcm_oss.c   4 Jul 2003 08:49:53 -0000       1.38
+++ pcm_oss.c   12 Jul 2003 19:21:16 -0000      1.39
@@ -1990,12 +1990,20 @@
        }
        if (csubstream != NULL) {
                snd_pcm_runtime_t *runtime = csubstream->runtime;
+               enum sndrv_pcm_state ostate;
                poll_wait(file, &runtime->sleep, wait);
                snd_pcm_stream_lock_irq(csubstream);
-               if (runtime->status->state != SNDRV_PCM_STATE_RUNNING ||
+               if ((ostate = runtime->status->state) != SNDRV_PCM_STATE_RUNNING ||
                    snd_pcm_oss_capture_ready(csubstream))
                        mask |= POLLIN | POLLRDNORM;
                snd_pcm_stream_unlock_irq(csubstream);
+               if (ostate != SNDRV_PCM_STATE_RUNNING && runtime->oss.trigger) {
+                       snd_pcm_oss_file_t ofile;
+                       memset(&ofile, 0, sizeof(ofile));
+                       ofile.streams[SNDRV_PCM_STREAM_CAPTURE] = 
pcm_oss_file->streams[SNDRV_PCM_STREAM_CAPTURE];
+                       runtime->oss.trigger = 0;
+                       snd_pcm_oss_set_trigger(&ofile, PCM_ENABLE_INPUT);
+               }
        }
 
        return mask;



-------------------------------------------------------
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing & more.
Download & eval WebKing and get a free book.
www.parasoft.com/bulletproofapps1
_______________________________________________
Alsa-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/alsa-cvslog

Reply via email to