Bug 15814 - bash - internal printf no longer ignores options
Summary: bash - internal printf no longer ignores options
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: bash   
(Show other bugs)
Version: 7.0
Hardware: All Linux
Target Milestone: ---
Assignee: Bernhard Rosenkraenzer
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2000-08-09 13:37 UTC by Need Real Name
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-08-09 13:37:18 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Need Real Name 2000-08-09 13:37:16 UTC
RedHat Pinstripe Beta-5

From a bash shell, type:
	printf "-w 123\n"

and you get:
	bash: printf: illegal option: -w
	printf: usage: printf format [arguments]

Now with ash, or bash on RedHat 6.2 and earlier, or if you use
/usr/bin/printf,   you would get:
	-w 123

The bash man-page, printf section,  still does not indicate that there are
_any_ valid options - so why does it attempt to process them?

I am logging this as a serious defect because it breaks
backwards-compatability. There may be a number of customer-written scripts
which suddenly start to fail if they upgrade to RedHat 7.0.

Comment 1 Bernhard Rosenkraenzer 2000-08-14 14:45:29 UTC
POSIX compliance in bash 2.x - anything starting with "-" is an argument.
If you need the old behavior, use /usr/bin/printf.

Note You need to log in before you can comment on or make changes to this bug.