cygrunsrv + sshd + rsync = 20 times too slow -- throttled?

Takashi Yano takashi.yano@nifty.ne.jp
Thu Sep 9 08:05:49 GMT 2021


On Thu, 9 Sep 2021 12:41:15 +0900
Takashi Yano wrote:
> diff --git a/winsup/cygwin/fhandler_fifo.cc b/winsup/cygwin/fhandler_fifo.cc
> index 6709fb974..c40573783 100644
> --- a/winsup/cygwin/fhandler_fifo.cc
> +++ b/winsup/cygwin/fhandler_fifo.cc
> @@ -1047,6 +1047,12 @@ writer_shmem:
>    ResetEvent (writer_opening);
>    nwriters_unlock ();
>  success:
> +  if (!select_sem)
> +    {
> +      char name[MAX_PATH];
> +      __small_sprintf(name, "semaphore-%W", get_pipe_name ()->Buffer);
> +      select_sem = CreateSemaphore (&sec_none, 0, INT32_MAX, name);
> +    }
>    return 1;
>  err_close_reader:
>    saved_errno = get_errno ();

Should this be:
> +      select_sem = CreateSemaphore (sa_buf, 0, INT32_MAX, name);
?

-- 
Takashi Yano <takashi.yano@nifty.ne.jp>


More information about the Cygwin-developers mailing list