From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4257 invoked by alias); 13 Nov 2004 21:43:39 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 4234 invoked from network); 13 Nov 2004 21:43:33 -0000 Received: from unknown (HELO balder.inter.net.il) (192.114.186.15) by sourceware.org with SMTP; 13 Nov 2004 21:43:33 -0000 Received: from zaretski ([80.230.158.138]) by balder.inter.net.il (Mirapoint Messaging Server MOS 3.3.7-GR) with ESMTP id DWC21950 (AUTH halo1); Sat, 13 Nov 2004 23:42:46 +0200 (IST) Date: Sat, 13 Nov 2004 21:46:00 -0000 From: "Eli Zaretskii" To: Daniel Jacobowitz Message-ID: <01c4c9c9$Blat.v2.2.2$913fbf20@zahav.net.il> Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=ISO-8859-1 CC: otto.wyss@orpatec.ch, gdb@sources.redhat.com In-reply-to: <20041113201803.GA21320@nevyn.them.org> (message from Daniel Jacobowitz on Sat, 13 Nov 2004 15:18:03 -0500) Subject: Re: GDB doesn't show the correct line Reply-to: Eli Zaretskii References: <40D5E480.4A68163@orpatec.ch> <20040620202929.GA17216@nevyn.them.org> <40D7212F.E68A9D61@orpatec.ch> <20040621175928.GA13407@nevyn.them.org> <40D725AF.FC2AAF3A@orpatec.ch> <20041113201803.GA21320@nevyn.them.org> X-SW-Source: 2004-11/txt/msg00130.txt.bz2 > Date: Sat, 13 Nov 2004 15:18:03 -0500 > From: Daniel Jacobowitz > Cc: gdb@sources.redhat.com > > It's no one's fault, I think. I tracked down the problem. You have > mixed newline conventions in the file: mostly "\n" as a line separator, > but in some places just "\r". GCC treats this as a line break for > legacy reasons (MacOS). 'less' doesn't, which really confused me while > trying to debug the problem. GDB doesn't, either. > > Should GDB? I have no idea. As of today, GDB should treat \r\n (a.k.a. CR-LF) line endings correctly, but not sole \r. Perhaps we should amend that code to treat sole CRs as well. > But it's easiest to just fix the source file to be consistent. Indeed.