GNU bug report logs - #11991
shell file globbing confusion

Previous Next

Package: coreutils;

Reported by: "Xiao, Bellon (NSN - CN/Cheng Du)" <bellon.xiao <at> nsn.com>

Date: Thu, 19 Jul 2012 16:16:03 UTC

Severity: normal

Tags: notabug

Done: Bob Proulx <bob <at> proulx.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: "Xiao, Bellon (NSN - CN/Cheng Du)" <bellon.xiao <at> nsn.com>
To: 11991 <at> debbugs.gnu.org
Cc: "Han, Cathy \(NSN - CN/Cheng Du\)" <cathy.han <at> nsn.com>
Subject: bug#11991: tr bug
Date: Thu, 19 Jul 2012 14:38:55 +0800
[Message part 1 (text/plain, inline)]
Hi,

We found a bug of tr, the version is tr (coreutils) 5.2.1
Here is the symptom:
When there is a file named e or r under current directory, tr will take effect,like:
	echo hello |tr [a-z] [A-Z] 
	echo hello |tr [:lower:] [:upper:]
will return hello

And when is a file named l, o, p, u or w under current directory, tr will give error message like:
	echo hello |tr [a-z] [A-Z] 
	echo hello |tr [:lower:] [:upper:]
gives : tr: misaligned [:upper:] and/or [:lower:] construct


But if you try 
	echo kkhh |tr "[a-z]" "[A-Z]" 
	echo kkhh |tr "[:lower:]" "[:upper:]"
There will be no error and it takes effect.

Brs
Bellon Xiao


[Message part 2 (text/html, inline)]

This bug report was last modified 12 years and 311 days ago.

Previous Next


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