bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: printf "%c" - fixed


From: Chet Ramey
Subject: Re: printf "%c" - fixed
Date: Sun, 15 Aug 2004 19:36:19 -0400
User-agent: Mozilla/5.0 (Windows; U; Win 9x 4.90; en-US; rv:1.6) Gecko/20040113

GVK wrote:

Hello,
This is my first time messing with some source-code. Someone on Savannah complained that printf "%c" [int] outputs the first digit instead of a character, i.e
$ printf "%c" 65
6
instead of expected output 'A'. So, I kinda fixed it :-)

The current bash behavior is that which is specified by posix.  I'm not
sure that printf is the correct place to be doing integer-ascii
conversion.

Chet




reply via email to

[Prev in Thread] Current Thread [Next in Thread]