From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8618 invoked by alias); 4 Apr 2019 05:27:20 -0000 Mailing-List: contact cygwin-developers-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-developers-owner@cygwin.com Mail-Followup-To: cygwin-developers@cygwin.com Received: (qmail 8606 invoked by uid 89); 4 Apr 2019 05:27:19 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-5.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=drawing, screen, explain X-HELO: conssluserg-06.nifty.com Received: from conssluserg-06.nifty.com (HELO conssluserg-06.nifty.com) (210.131.2.91) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 04 Apr 2019 05:27:17 +0000 Received: from Express5800-S70 (ntsitm424054.sitm.nt.ngn.ppp.infoweb.ne.jp [219.97.74.54]) (authenticated) by conssluserg-06.nifty.com with ESMTP id x345RDBn032303 for ; Thu, 4 Apr 2019 14:27:13 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-06.nifty.com x345RDBn032303 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.ne.jp; s=dec2015msa; t=1554355634; bh=kKW5VcPrvZb1MZYgdxHmj3OqgEx1re8Wqvno3VmikO8=; h=Date:From:To:Subject:In-Reply-To:References:From; b=lpxpvetIGJ++wJePDtuXXJKkUUu72zust8ED3XtEmRq6N0Z25vMKGAZq3pmuCPLME Nq6p7pvDuydEhAnJpArhw+9PE5qHzgF9ZDfVTN+3mlBsQJBPxectcNyTGYbqxTxXzH mTbbPQROMKeJ++OlYpnHMRGJ1Wn7bkF9boolD8nzWM+1i4QBSHBr9tz7TUIGpIBBTR YdobxCUIHxmdN25rrT63EoiOxpQl5yPezm0uzCZ8JSxU/TN0ax+ETy8dSnmNgyrPV0 cWVUxLBtapdsevUcMuDxFst2Cz/PFTmdw7MKNUZChyDgj1aJYNZgx9PKZABmYkgOw7 gaBrDjHAfNVLg== Date: Thu, 04 Apr 2019 05:27:00 -0000 From: Takashi Yano To: cygwin-developers@cygwin.com Subject: Re: [PATCH v2 0/1] Pseudo console support in PTY (v2) Message-Id: <20190404142723.ef8c4bfb329671b60a9a2739@nifty.ne.jp> In-Reply-To: <20190403165029.GH3337@calimero.vinschen.de> References: <20190402110248.GP3337@calimero.vinschen.de> <20190403163621.2954-1-takashi.yano@nifty.ne.jp> <20190403165029.GH3337@calimero.vinschen.de> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2019-04/txt/msg00015.txt.bz2 Hi Corinna, On Wed, 3 Apr 2019 18:50:29 +0200 Corinna Vinschen wrote: > I will, but can you please outline the changes between v1 and v2 of your > patch? I'd like to understand the code and what the challenges are to > get this working. Major changes are as follows. (1) Pseudo console setup code in pty master is moved into the function setup_pseudoconsole(). (2) The code for pushing slave output into pseudo console screen buffer, which is for synchronization between real terminal and pseudo console screen buffer, is moved into the function push_to_pcon_screenbuffer(). (3) In push_to_pcon_screenbuffer(), add code which attach to pseudo console temporally if slave is not attached yet. (4) Call fhandler_console::need_invisible() in stdio_init() in dtable.cc instead of just returning from function when progname is "mintty". (5) Pushing slave output into pseudo console screen buffer is disabled when alternate screen buffer is used. (6) Change code page to 65001 (UTF-8) at startup of pty slave. (7) Remove "\033[6n" and "\033[0c", which generate report result in console input buffer, in the data to be pushed into pseudo console screen buffer. (8) Add some comments. (1) and (2) are not essential changes. (3) fixes the issue: On Thu, 4 Apr 2019 01:36:20 +0900 Takashi Yano wrote: > On Sat, 30 Mar 2019 22:08:04 +0900 Takashi Yano wrote: > > Known problems: > > * mintty fails to start if it is started in console cygwin > > session. > This has been resolved in the new version. (3) also makes it unnecessary the code returning from function stdio_init() in dtable.cc when progname is "mintty". (4) is for: On Tue, 2 Apr 2019 13:02:48 +0200 Corinna Vinschen wrote: > I found another weird effect which I can't explain off the top > of my head: system_printf() debug output does not show up > in a mintty anymore with this patch. Any idea why? howver, I am not sure why this solves the issue. (5) makes vim screen drawing speed up a little. (6) avoids garbled characters. (7) avoids the garbage in the input buffer for native console apps after vim is used. -- Takashi Yano