[alsa-devel] dmix in a forked process

Bankim Bhavsar bankim.bhavsar at gmail.com
Sun Aug 3 04:38:12 CEST 2008


Reading the source of alsa-lib I see that dmix runs in a forked process
*without* exec.

file: src/pcm/pcm_direct.c
function: snd_pcm_direct_server_create

       ret = fork();
       if (ret < 0) {
               close(dmix->server_fd);
               return ret;
       } else if (ret == 0) {
               ret = fork();
               if (ret == 0)
                       server_job(dmix);
               _exit(EXIT_SUCCESS);
       } else {
               waitpid(ret, NULL, 0);
       }



More information about the Alsa-devel mailing list