Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83 (MC830919); site mcvax.UUCP Path: utzoo!linus!philabs!mcvax!guido From: guido@mcvax.UUCP (Guido van Rossum) Newsgroups: net.bugs.4bsd Subject: Error in 4.2 BSD Bourne shell quoting Message-ID: <5441@mcvax.UUCP> Date: Mon, 24-Oct-83 10:52:07 EDT Article-I.D.: mcvax.5441 Posted: Mon Oct 24 10:52:07 1983 Date-Received: Tue, 25-Oct-83 23:02:22 EDT Organization: Math.Centre, Amsterdam Lines: 17 The following shell script doesn't work with the 4.2 BSD Bourne shell (sh): BIN=/bin : ${ECHO="$BIN/echo"} $ECHO $ECHO It replies with sh: /bin/echo: not found. The direct reason is that the variable ECHO has all the high order bits set (this was verified by exporting it and checking the environment from a C program). Probably the shell forgets to remove these bits (that it internally uses to remember quoted characters). Note that the following three alternatives for the second line all work: : ${ECHO="/bin/echo"} : ${ECHO=$BIN/echo} ECHO="$BIN/echo" The V7 shell on our PDP doesn't have the error. -- Guido van Rossum, {philabs,decvax}!mcvax!guido Centre for Mathematics and Computer Science, (CWI, formerly MC), Amsterdam