From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from conssluserg-03.nifty.com (conssluserg-03.nifty.com [210.131.2.82]) by sourceware.org (Postfix) with ESMTPS id 0A990386F447 for ; Mon, 18 May 2020 03:06:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 0A990386F447 Received: from Express5800-S70 (v040007.dynamic.ppp.asahi-net.or.jp [124.155.40.7]) (authenticated) by conssluserg-03.nifty.com with ESMTP id 04I35Ufx016508; Mon, 18 May 2020 12:05:31 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-03.nifty.com 04I35Ufx016508 X-Nifty-SrcIP: [124.155.40.7] Date: Mon, 18 May 2020 12:05:34 +0900 From: Takashi Yano To: cygwin@cygwin.com Subject: Re: Suspend doesn't work in cmd Message-Id: <20200518120534.97f3515d2295301421f585ae@nifty.ne.jp> In-Reply-To: References: X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-5.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, 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: Mon, 18 May 2020 03:06:17 -0000 On Sun, 17 May 2020 19:57:15 +0200 Kacper Michajlow via Cygwin wrote: > Hi, > > Control keys doesn't seem to be working correctly under cmd. > > STR: > 1. Run bash in cmd.exe > 2. Run anything, in my case "seq 1 100000" > 3. Try to suspend job with CTRL+Z or suspend printing with CTRL+S > > Ii will ignore request. Works in mintty, doesn't in cmd. Thanks for the report. This is a known problem, however, it is hard to fix soon. In current console implementation, ctrl-Z is processed in read() system call. So, if process does not call read(), ctlr-Z does not work. You can confirm that ctrl-Z works for cat, od, etc. which calls read(). One solution might be to introduce a thread to handle the keystrokes. I wonder if it is worth enough to introduce such a big modification for console code. -- Takashi Yano