[comp.unix.ultrix] Bug in /bin/csh: echo "`date`" in script

epmcmanus@csvax1.cs.tcd.ie (07/12/89)

There is a bug in the Ultrix 3.0 csh which was not present in Ultrix 2.2.
I would guess that support for 8-bit characters is the reason for the change.

The script:
	#!/bin/csh
	echo "`date`"
causes character 0xFF to be output before each character of the date.  The
same thing happens for other commands, and for:
	% csh -c 'echo "`date`"'
but not for:
	% echo "`date`"
-- 
Eamonn McManus		emcmanus@cs.tcd.ie	uunet!mcvax!cs.tcd.ie!emcmanus

envbvs@epb2.lbl.gov (Brian V. Smith) (07/12/89)

In article <49802@csvax1.cs.tcd.ie>, epmcmanus@csvax1.cs.tcd.ie writes:
< 
< There is a bug in the Ultrix 3.0 csh which was not present in Ultrix 2.2.
< I would guess that support for 8-bit characters is the reason for the change.
< 
< The script:
< 	#!/bin/csh
< 	echo "`date`"
< causes character 0xFF to be output before each character of the date.  The
< same thing happens for other commands, and for:
< 	% csh -c 'echo "`date`"'
< but not for:
< 	% echo "`date`"

Yes, I reported the bug to comp.unix.ultrix in May.  Win Treese of Digital
replied that "it is a known bug, but didn't know when it would be fixed".

Maybe in 3.1?

_____________________________________
Brian V. Smith    (bvsmith@lbl.gov)
Lawrence Berkeley Laboratory

grr@cbmvax.UUCP (George Robbins) (07/13/89)

In article <49802@csvax1.cs.tcd.ie> Eamonn McManus <emcmanus@cs.tcd.ie> writes:
> There is a bug in the Ultrix 3.0 csh which was not present in Ultrix 2.2.
> I would guess that support for 8-bit characters is the reason for the change.
> 
> 	#!/bin/csh
> 	echo "`date`"
> causes character 0xFF to be output before each character of the date.

There are quite a few places where 8-bit characters vs. traditional
internal "quoting" mechanisms or their replacements read threir ugly
head.

The workaround for this one is supposedly to install /usr/new/csh (aka tcsh)
as /bin/csh.  Supposedly tcsh doesn't have this bug and is otherwise
reasonably compatible.  You also get an inactivity logout, which can be
irritating unless you put 'unset autologout' in your .login file.

Other places with 8-bit screw-ups:

When csh types out "job names" with the jobs command, fg, bg and when
a task terminates.

When you use one of the filename substitition metachacters in a shell
escape from vi/ex.  Example:   :!pr %  will get 'pr: can't open xyz'
even though xyz already exists.
-- 
George Robbins - now working for,	uucp: {uunet|pyramid|rutgers}!cbmvax!grr
but no way officially representing	arpa: cbmvax!grr@uunet.uu.net
Commodore, Engineering Department	fone: 215-431-9255 (only by moonlite)

avolio@decuac.dec.com (Frederick M. Avolio) (07/13/89)

Seems to be fixed in ULTRIX 3.1.

Fred