From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from Ishtar.sc.tlinx.org (ishtar.tlinx.org [173.164.175.65]) by sourceware.org (Postfix) with ESMTPS id 5BF0B3858002 for ; Sun, 14 Feb 2021 20:46:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 5BF0B3858002 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tlinx.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=cygwin@tlinx.org Received: from [192.168.3.12] (Athenae [192.168.3.12]) by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id 11EKkEA8058923; Sun, 14 Feb 2021 12:46:17 -0800 Message-ID: <60298BB0.1070301@tlinx.org> Date: Sun, 14 Feb 2021 12:44:32 -0800 From: L A Walsh User-Agent: Thunderbird 2.0.0.24 (Windows/20100228) MIME-Version: 1.0 To: Takashi Yano CC: cygwin@cygwin.com, Alvin Seville Subject: Re: Cygwin doesn't handle SIGWINCH properly in Windows Terminal References: <20210214174358.f828f285a566846254c3c54a@nifty.ne.jp> In-Reply-To: <20210214174358.f828f285a566846254c3c54a@nifty.ne.jp> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, 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, 14 Feb 2021 20:46:19 -0000 On 2021/02/14 00:43, Takashi Yano via Cygwin wrote: > This is because cygwin console handles SIGWINCH when the input > messages is processed. If the process does not call either read() > or select(), SIGWINCH will not be sent. This is the long standing > problem of the implementation and hard to fix. > > .... > > This seems to be a bug of console code. I will submit a patch > for this issue. > --- I'd be careful 'fixing' this, as it seems to work the same way on linux / bash. I have this func setup on bash_profile & bashrc on both cygwin and linux: # display new size of terminal when resized : showsize () {\ declare s=$(stty size); s="(${s// /x})" ;\ printf "%s" "$s${s//?/$'\b'}" ;\ }; export -f showsize trap showsize SIGWINCH ----- Of note, on linux, I didn't have to reset LINES/COLUMNS, however, on cygwin, I note that I should. Oh well -- hmmm....is that a bug?