Hi Mark,

On Mar 13 23:44, Mark Geisert wrote:
> For a very long time, since 2011 or earlier, fork() has printed an internal
> error message when it fails due to a CreateProcess() error.  This patch
> quashes the error message as far as the user can tell, but it will still be
> present in an strace.
> 
> This change is a judgement call based on the fact we now support
> RLIMIT_NPROC and so a user limiting the number of subprocesses may hit
> more CreateProcess() errors by design.  Don't clutter the scene.
> 
> Fixes: 855108782321 (* dll_init.c (dll_list::load_after_fork): Don't
> clear in_forkee here.)
> Signed-off-by: Mark Geisert <[email protected]>
> 
> ---
>  winsup/cygwin/fork.cc | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc
> index 3e5d81fe4..48e8b7557 100644
> --- a/winsup/cygwin/fork.cc
> +++ b/winsup/cygwin/fork.cc
> @@ -400,6 +400,7 @@ frok::parent (volatile char * volatile stack_here)
>       {
>         this_errno = geterrno_from_win_error ();
>         error ("CreateProcessW failed for '%W'", myself->progname);
> +       ch.silentfail (true);
>         dlls.release_forkables ();
>         memset (&pi, 0, sizeof (pi));
>         goto cleanup;
> -- 
> 2.51.0

This and the typo fix pushed.

Thanks,
Corinna

Reply via email to