From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 22 12:27:40 2015 Received: (at submit) by debbugs.gnu.org; 22 Jan 2015 17:27:40 +0000 Received: from localhost ([127.0.0.1]:53179 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YELXg-0004fL-0a for submit@debbugs.gnu.org; Thu, 22 Jan 2015 12:27:40 -0500 Received: from eggs.gnu.org ([208.118.235.92]:44747) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YEERY-0006pm-0X for submit@debbugs.gnu.org; Thu, 22 Jan 2015 04:52:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YEERR-00041v-PG for submit@debbugs.gnu.org; Thu, 22 Jan 2015 04:52:46 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:49032) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEERR-00041r-Lz for submit@debbugs.gnu.org; Thu, 22 Jan 2015 04:52:45 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46446) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEERQ-00079W-8H for bug-coreutils@gnu.org; Thu, 22 Jan 2015 04:52:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YEERP-00040z-8j for bug-coreutils@gnu.org; Thu, 22 Jan 2015 04:52:44 -0500 Received: from mail-ob0-x22e.google.com ([2607:f8b0:4003:c01::22e]:60831) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEERP-00040e-4z for bug-coreutils@gnu.org; Thu, 22 Jan 2015 04:52:43 -0500 Received: by mail-ob0-f174.google.com with SMTP id gq1so533088obb.5 for ; Thu, 22 Jan 2015 01:52:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=zdiW0/xy5TKt8GJp+MiC5xyE73Yh3Dt4LbhLunKmnrw=; b=Xp93j1dUK4UAdVm5m5VtTFthPXarUvGSxavAWRvYCRYoR37SxbFncLlc/vJkflMKid 9g1wtpEHS829WLjqhRniMaay6LzzOi/6nhOxfQ7GXv1FTUy4659mpXFfxpxs5L5BT4be s0la2/A4UzNv0Uo07vKJqkEo5Ukgwe9eWXpBVbviINPAR5BkybuMhZmVlEsy+RRJrvuu yHDsD5ggotg0TDX2Z4a7jf7vc+u1oQOc7Mk3QXRTEKf/p2wFguv82p4ZWz/uGUplmCpX 3D/gF8cQ3XK8lpfBlPICPbRPofbbbwCZilao6kayqj8QBTeLKJoWubLTUKOj0i8QweMA ACUQ== MIME-Version: 1.0 X-Received: by 10.202.56.84 with SMTP id f81mr214601oia.101.1421920362106; Thu, 22 Jan 2015 01:52:42 -0800 (PST) Received: by 10.202.102.130 with HTTP; Thu, 22 Jan 2015 01:52:42 -0800 (PST) Date: Thu, 22 Jan 2015 15:22:42 +0530 Message-ID: Subject: tr command odd behavior on Linux Platform From: Kousik Mandal To: bug-coreutils@gnu.org Content-Type: multipart/alternative; boundary=001a113cb976151482050d3aa278 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 22 Jan 2015 12:27:38 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) --001a113cb976151482050d3aa278 Content-Type: text/plain; charset=UTF-8 Hi Team, I am observing an unexpected behavior with tr command. In a directory if there exist one file named a and executing following tr command. ---script--- myVar="Hello World" $ echo $myVar|tr [A-Z] [a-z] ---script--- It gives Output: aello aorld Where as if there exist another file/directory named b then the same command it failing with below error ---script--- myVar="Hello World" $ echo $myVar|tr [A-Z] [a-z] ---script--- Output: tr: extra operand `b' Try `tr --help' for more information. If only file b is present then the same command is not failing but it give wrong output. ---script--- myVar="Hello World" $ echo $myVar|tr [A-Z] [a-z] ---script--- Output: Hello World Same type of observation found if only a single alphabetic name file or directory is exist. Can you please update me it is a bug or expected behavior? Thanks, Kousik --001a113cb976151482050d3aa278 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Team,

I am observing an unexpected behavior with= tr command. In a directory if there exist one file named a and executing f= ollowing tr command.
---script---
myVar=3D"Hello World"
= $ echo $myVar|tr [A-Z] [a-z]
---script---

It gives Output: aello = aorld

Where as if there exist another file/directory named b then th= e same command it failing with below error

---script---
myVar=3D&= quot;Hello World"
$ echo $myVar|tr [A-Z] [a-z]
---script---
<= br>Output:
tr: extra operand `b'
Try `tr --help' for more inf= ormation.

If only file b is present then the same command is not fai= ling but it give wrong output.

---script---
myVar=3D"Hello W= orld"
$ echo $myVar|tr [A-Z] [a-z]
---script---

Output:Hello World

Same type of observation found if only a single alphab= etic name file or directory is exist.

Can you please update me it is= a bug or expected behavior?

Thanks,
Kousik

--001a113cb976151482050d3aa278-- From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 22 13:11:58 2015 Received: (at 19654) by debbugs.gnu.org; 22 Jan 2015 18:11:58 +0000 Received: from localhost ([127.0.0.1]:53209 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YEMEY-0005pB-0d for submit@debbugs.gnu.org; Thu, 22 Jan 2015 13:11:58 -0500 Received: from mail2.vodafone.ie ([213.233.128.44]:29212) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YEMEU-0005oo-LV; Thu, 22 Jan 2015 13:11:55 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AlIJAC09wVRtTfQc/2dsb2JhbABagwZSWIEjgRJPwzoKhW4BAgKBFkMBAQEBAX2EDQEBBAECIA8BVgsNCwICBRYLAgIJAwIBAgEWLwYBDAgBAYgsAQi/AYVpjnAsgSGOX4JogUEFkjCDMoNnhH6LbSKDbj4xAYJCAQEB Received: from unknown (HELO localhost.localdomain) ([109.77.244.28]) by mail2.vodafone.ie with ESMTP; 22 Jan 2015 18:11:47 +0000 Message-ID: <54C13D63.7060700@draigBrady.com> Date: Thu, 22 Jan 2015 18:11:47 +0000 From: =?UTF-8?B?UMOhZHJhaWcgQnJhZHk=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: Kousik Mandal , 19654@debbugs.gnu.org Subject: Re: bug#19654: tr command odd behavior on Linux Platform References: In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 19654 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) tag 19654 notabug close 19654 stop On 22/01/15 09:52, Kousik Mandal wrote: > Hi Team, > > I am observing an unexpected behavior with tr command. In a directory if there exist one file named a and executing following tr command. This is becoming a FAQ: http://lists.gnu.org/archive/html/coreutils/2014-12/msg00041.html thanks, Pádraig. From unknown Fri Jun 20 07:19:03 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 20 Feb 2015 12:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator