Red Hat Bugzilla – Bug 12840
printf(1) man page misformatted
Last modified: 2008-05-01 11:37:56 EDT
I typed "man printf" by mistake instead of "man 3 printf" and noticed that
the printf(1) man page from sh-utils-2.0-5 isn't formatted correctly. This
seems to be because backslashes aren't escaped correctly in the man page
source. The man page is apparently generated by help2man 1.012, so I guess
this may actually be a help2man error. I know that GNU doesn't maintain man
pages, but I thought I'd bring this up anyway.
The section with the bad formatting is:
FORMAT controls the output as in C printf. Interpreted
NNN character with octal value NNN (0 to 3 digits)
c.... alert (BEL)
s.TP produce no further output
N character with hexadecimal value NNN (1 to 3 dig-
I also get the following error messages:
<standard input>:44: a newline character is not allowed in an escape name
<standard input>:47: a newline character is not allowed in an escape name
<standard input>:56: cannot use newline as a starting delimiter
<standard input>:59: warning: numeric expression expected (got `N')
The relevant section of the source seems to be:
FORMAT controls the output as in C printf. Interpreted sequences are:
.TP \" double quote
.TP \0NNN character with octal value NNN (0 to 3 digits)
.TP \\ backslash
.TP \a alert (BEL)
produce no further output
character with hexadecimal value NNN (1 to 3 digits)
Still is still an issue (in Rawhide).
The problem here is the too old version of help2man. A newer version obtained
from ftp://ftp.gnu.org/gnu/help2man/ can escape backslashes properly.
Fixed in sh-utils-2.0-12.
*** Bug 17046 has been marked as a duplicate of this bug. ***