Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mark Kettenis <kettenis@gnu.org>
To: gdb-patches@sources.redhat.com
Subject: [COMMIT] Accept "\r\n" line-endings on all hosts
Date: Thu, 14 Oct 2004 12:44:00 -0000	[thread overview]
Message-ID: <200410141244.i9ECiXMQ008862@elgar.sibelius.xs4all.nl> (raw)

In the discussion about elimination of the Cygwin and DJGPP xm.h files
we seemed to have reached agreement on this.  Actually this is a real
improvement, since it will allow you to execute scripts copied from a
system using the MS-DOS convention without converting them.

Tested on i386-unknown-freebsd4.7.

Mark

Index: ChangeLog
from  Mark Kettenis  <kettenis@gnu.org>

	* top.c (gdb_readline): Always accept "\r\n" as a line-ending.
	* event-top.c (gdb_readline2): Likewise.

Index: top.c
===================================================================
RCS file: /cvs/src/src/gdb/top.c,v
retrieving revision 1.93
diff -u -p -r1.93 top.c
--- top.c 13 Sep 2004 18:26:30 -0000 1.93
+++ top.c 14 Oct 2004 12:30:25 -0000
@@ -932,15 +932,11 @@ gdb_readline (char *prompt_arg)
 	}
 
       if (c == '\n')
-#ifndef CRLF_SOURCE_FILES
-	break;
-#else
 	{
 	  if (input_index > 0 && result[input_index - 1] == '\r')
 	    input_index--;
 	  break;
 	}
-#endif
 
       result[input_index++] = c;
       while (input_index >= result_size)
Index: event-top.c
===================================================================
RCS file: /cvs/src/src/gdb/event-top.c,v
retrieving revision 1.34
diff -u -p -r1.34 event-top.c
--- event-top.c 13 Sep 2004 18:26:28 -0000 1.34
+++ event-top.c 14 Oct 2004 12:30:27 -0000
@@ -855,15 +855,11 @@ gdb_readline2 (gdb_client_data client_da
 	}
 
       if (c == '\n')
-#ifndef CRLF_SOURCE_FILES
-	break;
-#else
 	{
 	  if (input_index > 0 && result[input_index - 1] == '\r')
 	    input_index--;
 	  break;
 	}
-#endif
 
       result[input_index++] = c;
       while (input_index >= result_size)


             reply	other threads:[~2004-10-14 12:44 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-10-14 12:44 Mark Kettenis [this message]
2004-10-14 13:47 ` Andrew Cagney
2004-10-14 18:37   ` Mark Kettenis
2004-10-14 19:09     ` Andrew Cagney
2004-10-14 19:48       ` Mark Kettenis
2004-10-14 19:59         ` Andrew Cagney
2004-10-15  2:16         ` Michael Chastain
2004-10-14 21:11     ` Eli Zaretskii
2004-10-14 23:03       ` Andreas Schwab
2004-10-15 12:43         ` Eli Zaretskii
2004-10-15 13:48           ` Andreas Schwab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200410141244.i9ECiXMQ008862@elgar.sibelius.xs4all.nl \
    --to=kettenis@gnu.org \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox