From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 56805 invoked by alias); 17 Jan 2020 16:40:15 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 56791 invoked by uid 89); 17 Jan 2020 16:40:15 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=4.3 required=5.0 tests=AWL,BAYES_00,GARBLED_BODY,SPF_HELO_PASS,SPF_PASS autolearn=no version=3.3.1 spammy=joy, xterm, TERM, judge X-HELO: ppsw-42.csi.cam.ac.uk Received: from ppsw-42.csi.cam.ac.uk (HELO ppsw-42.csi.cam.ac.uk) (131.111.8.142) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 17 Jan 2020 16:40:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=cam.ac.uk; s=20180806.ppsw; h=Content-ID:Content-Type:MIME-Version:Message-ID:Subject: To:From:Date:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-Description :Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=Lxdh4S7/CDZ/puHpuitx9afB8qkh1oSgU9LVHAch9Hw=; b=ciZ9+LRShjvPxyql2WIKQM2I8S wTxt63xOjGJNP0W+W5eVKNZWWI6AQRs6K+NBw0u0RtuMI8JTEiytALmnnV7YvUrMvxWHJjKtya8aO RSIiCw+Vwp5VlvQZZw+fgvOsXGy0pBdUtwvTdFXucBWc4GYHlnj0Ry8YCfg7fQx/kJ6w=; Received: from host86-156-0-112.range86-156.btcentralplus.com ([86.156.0.112]:2028 helo=panamint) by ppsw-42.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.158]:465) with esmtpsa (PLAIN:acn1) (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) id 1isUfC-0013CT-9L (Exim 4.92.3) for cygwin@cygwin.com (return-path ); Fri, 17 Jan 2020 16:40:02 +0000 Date: Fri, 17 Jan 2020 16:40:00 -0000 From: Arthur Norman To: cygwin@cygwin.com Subject: cgdb terminal handling problems Message-ID: User-Agent: Alpine 2.00 (WNT 1167 2008-08-23) MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="1258621-1454-1579274365=:48616" Content-ID: X-IsSubscribed: yes X-SW-Source: 2020-01/txt/msg00147.txt.bz2 --1258621-1454-1579274365=:48616 Content-Type: TEXT/PLAIN; FORMAT=flowed; CHARSET=UTF-8 Content-Transfer-Encoding: 8BIT Content-ID: Content-length: 3089 I have a trivial C++ program, which was tested using g++ -g hello.cpp -o hello cgdb ./hello break main run What gets displayed at that stage looks like the following where some of the long strings of escaped have been wrapped. There are funny characters marking "Line 5" which is where the breakpoint was. ~: ~: 1: #include 2: 3: int main(int argc, char *argv[]) 4: { 5├> std::cout << "Hello" << std::endl; 6: return 0; 7: } 8: ~: ~: /home/acn1/hello.cpp [80X[80C[?25h[?25lbreakpoints-invalid[?25h[?25l [80X[80C[?25h[?25l[80X[80C[?25h[?25l Breakpoint 1,[67X[67C[?25h[?25l[80X[80C[?25h[?25lmain[76X[76C[?25h[?25l ([78X[78 C[?25h[?25largc[76X[76C[?25h[?25l=[79X[79C[?25h[?25l1[79X[79C[?25h[?25l,[79X[79C [?25h[?25largv[76X[76C[?25h[?25l=[79X[79C[?25h[?25l [80X[80C[?25h[?25larg-value *[?25h[?25l 0xffffcc40[70X[70C[?25h[?25l)[79X[79C[?25h[?25l at[77X[77C[?25h[?25lhello.cpp[71 X[71C[?25h[?25l:[79X[79C[?25h[?25l5[79X[79C[?25h[?25l[80X[80C[?25h[?25l[?25h[?25 l [80X[80C[?25h[?25l[80X[80C[?25h[?25l[80X[80C[?25h[?25l[80X[80C[?25h[?25l(gdb)[75 X[75C[?25h[?25l and you can see the mess of terminal-control escapes that unhelpfully appear. My terminal there is then not as responsive as I would like so progressing is hard. I can go ^Z to exit and then use kill to terminate the cgdb session. The above trasncript was collected by using COPY&PASTE from the terminal screen. But all those "[80C" etc etc appear as characters on my terminal just as such. When I go "echo $TERM" I see the default "xterm" and SHELL is /bin/bash - all that is just as per the default when cygwin was installed. To ensure that this was not a matter of other interfering applications I installed a totally fresh Windows 10 and then (perhaps apart from virtualbox tools) only cygwin. For Cygwin I only install cgdb, gdb and g++, using the latest non-testing version of each. But having done that I tried other versions og gdb & cgdb without joy. This sort of behaviour in cgdb seems to have arisen some time in the last few weeks. If I back off to cygwin 3.1.1-1 I still see trouble but with 3.0.7-1 things appear to behave better for this. However with a larger real program I just got (gdb) step __wrap__Znam (sz=80000000) at /usr/src/debug/cygwin-3.0.7-1/winsup/cygwin/libstd cxx_wrapper.cc:61 (gdb) s /wip/cygport-git/gdb/gdb-8.2.1-1.x86_64/src/gdb-8.2.1/gdb/infrun.c:2723: intern A problem internal to GDB has been detected, further debugging may prove unreliable. Since that may be a metter of using an old cygwin I will wait before I try to produce a version of that worth reporting! But this looks like an underlying cygwin change upsetting gdb or cgdb??? [In some code of my own I was bitten because something has fairly recently changes and the Windows call GetConsoleScreenBufferInfo now succeeds in a cygwin program running under mintty while it used not to - I had used that test to judge whether I could or should use Windows-mode console handling on Unix-style... I sort of wonder if this is a variant on my problem there?] Arthur --1258621-1454-1579274365=:48616 Content-Type: text/plain; charset=us-ascii Content-length: 219 -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple --1258621-1454-1579274365=:48616--