GNU bug report logs - #8587
Curious bug.

Previous Next

Package: coreutils;

Reported by: Francois Boisson <francois <at> boisson.homeip.net>

Date: Fri, 29 Apr 2011 20:17:02 UTC

Severity: normal

Tags: notabug

Done: Eric Blake <eblake <at> redhat.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Pádraig Brady <P <at> draigBrady.com>
To: Francois Boisson <francois <at> boisson.homeip.net>
Cc: 8587 <at> debbugs.gnu.org
Subject: bug#8587: Curious bug.
Date: Fri, 29 Apr 2011 22:06:56 +0100
On 29/04/11 20:09, Francois Boisson wrote:
> On a debian squeeze amd64.
> 
> francois <at> totoche:~$ echo ABCD Directory | tr [:lower:] [:upper:] 
> ABCD DIRECTORY
> francois <at> totoche:~$ cd /tmp
> francois <at> totoche:/tmp$ echo ABCD Directory | tr [:lower:] [:upper:] 
> tr: construit [:upper:] et/ou [:lower:] mal aligné

So the operation is dependent on path.
That shows the shell is interpreting the params,
as demonstrated with:

$ touch l
$ echo [:lower:] [:upper:]
l [:upper:]

So you need to protect the params like:

$ tr '[:lower:]' '[:upper:]'

cheers,
Pádraig.




This bug report was last modified 14 years and 27 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.