Hello Bastien, > I do not know how to replace the fork() on windows.
It's replaced by doing a spawn to a separate program. Take for example the files modules/nonblocking-pipe-tests tests/test-nonblocking-pipe.sh tests/test-nonblocking-pipe-main.c tests/test-nonblocking-pipe-child.c that were committed in gnulib two days ago. The essential points are: - Use a separate program for the child process(es). - Use posix_spawnp on Unix, spawnvpe on native Windows to spawn the child process. (Our posix_spawnp does not yet work on mingw.) - You can pass command-line options and stdin, stdout to the child process; file descriptors > 2 cannot be passed to child processes on Windows, I think. Bruno -- In memoriam Charles Delestraint <http://en.wikipedia.org/wiki/Charles_Delestraint>