Fix rather large performance issue on systems with slow fork syscall - a fork was used whenever redirecting output to /dev/null and using a builtin, completely unneeded.

darcs-hash:20070921214955-75c98-b513df263751506e5e82f97eafa08041228bc8de.gz
This commit is contained in:
liljencrantz 2007-09-22 07:49:55 +10:00
parent 048f903a9d
commit 1420744669

2
exec.c
View File

@ -1346,7 +1346,7 @@ void exec( job_t *j )
for( io = j->io; io; io=io->next )
{
if( io->io_mode == IO_FILE )
if( io->io_mode == IO_FILE && wcscmp(io->param1.filename, L"/dev/null" ))
{
skip_fork = 0;
}