Date: Wed, 16 Aug 2000 15:33:55 +0200 (CEST) From: Jappe Reuling <jappe@lowlife.org> To: freebsd-bugs@FreeBSD.ORG Subject: I think I found a bug in /bin/sh Message-ID: <Pine.BSF.4.21.0008161520460.4876-100000@bsd.t-l.org>
next in thread | raw e-mail | index | archive | help
Hi,
While writing a shell script I came acros something strange. I used an
alias for 'echo' and it looks like the alias is ignored in a case
statement. The code below produces the following on the screen:
----
H
e
l
l
o
Hello
----
----
#!/bin/sh
alias echo="/bin/echo -n"
hello() {
local foo
foo=1
case $foo in
1)
echo "H"
echo "e"
echo "l"
echo "l"
echo "o"
;;
esac
echo "H"
echo "e"
echo "l"
echo "l"
echo "o"
}
hello
----
Hope this report helps.
Jappe Reuling
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0008161520460.4876-100000>
