Date: Fri, 27 Mar 1998 20:27:46 +0530 (IST) From: "Mahadevan R." Reply-To: mdevan AT iname DOT com To: djgpp AT delorie DOT com Subject: "bash"ing "cat"s. Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk Hi all. This is with reference to the recent thread about "cat -", wherein, I gather, it was concluded that this was a problem specific to "cat". But on my system.. C:\>bash bash$ cat - ^Z bash$ tac - bash$ gawk --file=- bash$ expand - bash$ as bash$ Now this is even funnier: C:\>bash bash$ cat - ^Z bash$ wc 0 0 0 bash$ wc I find that the above sequence can be generalized to: C:\>bash bash$ cat - ^Z bash$ bash$ o/p of above pgm bash$ cat Programs of the first category include addr2line (binutils), gasp (binutils), gawk (gawk) and a horde of others, from various packages, and hence I suppose bash is the culprit. ls, "cat non_existing_file" etc. come under the second category. And just to test that it is the printing-to-the-screen part that nullifies the anomaly: C:\>bash bash$ cat - # simply "cat" will do, BTW ^Z bash$ any_program >/dev/null 2>&1 bash$ cat bash$ Finally, just one more thing: C:\>bash bash$ cat ^Z bash$ cat # funny behaviour starts.. bash$ cat autoexec.bat config.sys utils (completions displayed by bash) bash$ cat # cmd line redisplayed by bash, just hit enter bash$ cat # funny behaviour continues.. bash$ Comments ? (Sorry about the new thread, this mail reader does not seem to know about RFC934 (or whatever)). Happy bashing, Mahesh (Mahadevan R.),