Close stdin/stdout/stderr in child processes before exec()