delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1997/01/15/22:40:13

From: cheekai AT gen DOT co DOT jp (Chin Chee-Kai)
Subject: 2 newlines instead of 1?
15 Jan 1997 22:40:13 -0800 :
Approved: cygnus DOT gnu-win32 AT cygnus DOT com
Distribution: cygnus
Message-ID: <Pine.3.07.9701161445.B1528-a100000.cygnus.gnu-win32@sumimasen.gen.co.jp>
Mime-Version: 1.0
X-Authentication-Warning: gensstc.gen.co.jp: smap set sender to <cheekai AT gen DOT co DOT jp> using -f
Original-To: gnu-win32 AT cygnus DOT com
In-Reply-To: <32DD94CE.1B938BCB@chromatic.com>
Original-Sender: owner-gnu-win32 AT cygnus DOT com

I run the all-time hello-world program to print a 1 line
"Hello world\n".  On Unix, it gives, as expected, the following:

	% a.out
	Hello world!
	% _

But in DOS, running a.exe gives:

	C:\Work>a
	Hello world!

	C:\Work>_

(where '_' indicates cursor position)

So there is one extra newline after the program's printing.
Piping the output to a text file such as "C:\Work\a > t.out"
similarly generated an extra newline in "t.out".

How'bout a fix on this?



Chin Chee-Kai (Last, First)
Internet Email-ID:	cheekai AT gen DOT co DOT jp
Gen Tech Corporation



-
For help on using this list, send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019