Bug 826139 - docbook2man escapes double-quotes in headings incorrectly
Summary: docbook2man escapes double-quotes in headings incorrectly
Alias: None
Product: Fedora
Classification: Fedora
Component: docbook-utils
Version: 17
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Ondrej Vasik
QA Contact: Fedora Extras Quality Assurance
Depends On:
Blocks: 826145
TreeView+ depends on / blocked
Reported: 2012-05-29 17:12 UTC by Jan Vcelak
Modified: 2013-03-04 01:30 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2012-05-30 12:26:26 UTC
Type: Bug

Attachments (Terms of Use)
source files for reproduction (10.89 KB, application/x-gzip)
2012-05-29 17:12 UTC, Jan Vcelak
no flags Details
proposed patch (228 bytes, patch)
2012-05-29 17:15 UTC, Jan Vcelak
no flags Details | Diff

Description Jan Vcelak 2012-05-29 17:12:35 UTC
Created attachment 587463 [details]
source files for reproduction

Description of problem:

If the title in the input SGML document contains double-quote character, it is escaped incorrectly and the output manual page is damaged.

Currently, the docbook2man-spec.pl script uses zero-width-character \& which is added before the double quote character. The purpose of zero-width-character is completely different [1]. Double-quote character in macro argument has to be replaced by double quote glyph \(dq or has to be doubled [2].

In case of docbook2man-spec.pl, the second approach is better, otherwise the order of the operations would have to be changed. The string is being converted to uppercase after the escaping, which would break the double quote glyph.

[1] http://www.gnu.org/software/groff/manual/html_node/Ligatures-and-Kerning.html
[2] http://www.gnu.org/software/groff/manual/html_node/Request-and-Macro-Arguments.html

Version-Release number of selected component (if applicable):
(and probably all others)

How reproducible:
Take a look at "man 5 fonts-conf", which is damaged. I'm attaching the source SGML files to reproduce and validate the fix.

Steps to Reproduce:
1. decompress the archive
2. run: docbook2man fontconfig-user.sgml
3. run: man ./fonts-conf.5 
Actual results:


Expected results:


Additional info:

This is not a bug in groff:

Comment 1 Jan Vcelak 2012-05-29 17:15:08 UTC
Created attachment 587464 [details]
proposed patch

Comment 2 Ondrej Vasik 2012-05-30 06:04:02 UTC
Thanks for the report and patch, Honza.

Comment 3 Ondrej Vasik 2012-05-30 12:26:26 UTC
Should be fixed by http://lists.fedoraproject.org/pipermail/scm-commits/2012-May/787200.html - docbook-utils-0.6.14-31.fc18 -> closing RAWHIDE.

Comment 4 Akira TAGOH 2012-05-31 09:49:11 UTC
Any plans to backport the fix for f17?

Comment 5 Ondrej Vasik 2012-06-01 08:31:58 UTC
I'll do an update for f16/f17 today...

Comment 6 Fedora Update System 2012-06-01 09:01:10 UTC
docbook-utils-0.6.14-30.fc16 has been submitted as an update for Fedora 16.

Comment 7 Fedora Update System 2012-06-01 09:04:45 UTC
docbook-utils-0.6.14-31.fc17 has been submitted as an update for Fedora 17.

Comment 8 Fedora Update System 2012-06-19 14:56:05 UTC
docbook-utils-0.6.14-30.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2012-06-19 14:56:38 UTC
docbook-utils-0.6.14-31.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

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