From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io1-xd36.google.com (mail-io1-xd36.google.com [IPv6:2607:f8b0:4864:20::d36]) by sourceware.org (Postfix) with ESMTPS id ED214386F037 for ; Sun, 31 May 2020 12:01:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org ED214386F037 Received: by mail-io1-xd36.google.com with SMTP id h4so794370iob.10 for ; Sun, 31 May 2020 05:01:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=DZWilyAfAWqHSpCY1GbER5ZuCHis8em/YehkqiYNtQ4=; b=Nto4+yhbcglHsmzf56dF40j59eqDqKFIzVoefN30D8M1ZIlcnctPCDOpfxlBOmQg9U 9D7eeSyQg8+b7EWWYQ9v3N3RKfIDxwzoP7hWlC6gbPCMabSNYU0iMx0acC71UyDilwUO gtxLAeTmHbg94jvONN9Q37MwCl3W0A6+1o6Z/DvBnkJysvMpTfldLj4mQ/g0AEj+J8lZ 8T1lhf6qz1dgMCHanv+I9cC/zt9gocik20qFqSjrg3YmgDEOjf3QAOazBk+aALhEh8CN o05ixbitKJbit3ubu1alCjYdHiEM8V2SYuMxiE30uNlKtMSheYuFK9byvntNUNIi5a0z FwSA== X-Gm-Message-State: AOAM531r5ihoOpBptkTkrn50m466CKm6WEhxuz32PnIqllpnNf+up8Gy PZDm80Pil7v7N6WTU/kCK1A2HhK9mPNOGdNVnMA= X-Google-Smtp-Source: ABdhPJyTMRt657ACytMKWjbkE7cX0KCkOdkCEsJREIWFLerhgi+4f7oWMUehdHw+nJfO74pgUFiit93iyU47C49JCS0= X-Received: by 2002:a02:cd2b:: with SMTP id h11mr10062462jaq.47.1590926462344; Sun, 31 May 2020 05:01:02 -0700 (PDT) MIME-Version: 1.0 References: <20200531010628.da3864bdc895a02b768bb694@nifty.ne.jp> <20200531180439.3f6a13db1ffa6ed1df39959a@nifty.ne.jp> In-Reply-To: <20200531180439.3f6a13db1ffa6ed1df39959a@nifty.ne.jp> From: Andrew Ng Date: Sun, 31 May 2020 13:00:51 +0100 Message-ID: Subject: Re: Repeated input in PTY with SSH when a native process runs a Cygwin process that consumes input To: Takashi Yano Cc: cygwin@cygwin.com Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-3.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: cygwin@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 May 2020 12:01:04 -0000 Hi Takashi, > The developers snapshot, in which the issue has been fixed, > is ready. Could you please test? Thanks for the fast response. I have tested the snapshot and can confirm that it fixes the issue. I have also applied the same fix to MSYS2 and confirmed the issue is fixed there too. I did take a look at the code when I came across this issue and I noticed a few things that looked a bit odd. I noticed that the following functions appear to make use of rabuf () without consideration for raixget (): fhandler_termios::eat_readahead fhandler_pty_master::accept_input fhandler_pty_master::transfer_input_to_pcon Also fhandler_pty_slave::eat_readahead does 'eols' processing without any guard on is_line_input (), which seems to differ from the code pattern seen elsewhere. I don't know if these are important, but thought I should mention them, just in case. Thanks, Andrew