Bug 6768 - /bin/echo does not process escape char \n
Summary: /bin/echo does not process escape char \n
Status: CLOSED DUPLICATE of bug 6498
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: bash   
(Show other bugs)
Version: 6.1
Hardware: i386
OS: Linux
high
high
Target Milestone: ---
Assignee: Cristian Gafton
QA Contact:
URL: http://www.resonate.com
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 1999-11-05 23:24 UTC by jcassell
Modified: 2008-05-01 15:37 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-11-09 16:27:02 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description jcassell 1999-11-05 23:24:52 UTC
/bin/echo and echo no longer interpret the newline escape
character embedded in a string. E.G.

TMP="This is some text"
TMP=${TMP}"\nwith a newline in the middle"

/bin/echo ${TMP}

This code work fine in 6.0 and other flavors of unix:

This is some text
with a newline in the middle

but in RH 6.1 this is the output:

This is some text\nwith a newline in the middle

This bug has cost us a lot of time and money! What are you
guys smoking over there?! (sorry)

Comment 1 jcassell 1999-11-08 20:16:59 UTC
BTW, I neglected to mention, the bug-like echo behavior is exhibited
in a Bourne shell script - i.e. #!/bin/sh.

Comment 2 Bill Nottingham 1999-11-09 16:27:59 UTC
*** This bug has been marked as a duplicate of 6498 ***


Note You need to log in before you can comment on or make changes to this bug.