bugGNU troff - Bugs: bug #50771, mdoc(7) .Lk intends to handle...

 
 

bug #50771: mdoc(7) .Lk intends to handle punctuation, but fails to do so

Submitted by:  Ingo Schwarze <schwarze>
Submitted on:  Sun 09 Apr 2017 11:04:54 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: Incorrect behaviourStatus: Fixed
Privacy: PublicAssigned to: Carsten Kunze <carstenkunze>
Open/Closed: ClosedPlanned Release: 1.22.4

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 10 Apr 2017 07:53:44 AM UTC, comment #1:

Confirmed, I'll commit it soon. Thank you for reporting and fixing it.

Carsten Kunze <carstenkunze>
Project MemberIn charge of this item.
Sun 09 Apr 2017 11:04:54 PM UTC, original submission:

The implementation of the groff_mdoc(7) .Lk (hyperlink) macro contains code to make sure that the second argument is not punctuation before treating it as a link text, but the test can never lead to the result "punctuation" because the initialization of the global variable doc-width is missing before the call to doc-get-arg-type. Consequently, even "." is not recognized as punctuation:

$ nroff -mdoc
.Lk https://www.example.com/ .

results in:

.: https://www.example.com/

while the correct result would be:

https://www.example.com/.

Simple bugfix patch attached.

Problem reported by Anthony Bentley, bentley at openbsd dot org, fix by me.

Ingo Schwarze <schwarze>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #40340:  Lk-punct.patch added by schwarze (474B - text/x-patch)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by carstenkunze (Posted a comment)
  • -unavailable- added by schwarze (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 7 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 15 Apr 2017 09:18:22 AM UTCcarstenkunzeStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
      Planned ReleaseNone=>1.22.4
    Mon 10 Apr 2017 08:43:54 PM UTCcarstenkunzeStatusConfirmed=>Ready For Test
    Mon 10 Apr 2017 07:53:44 AM UTCcarstenkunzeStatusNone=>Confirmed
      Assigned toNone=>carstenkunze
    Sun 09 Apr 2017 11:04:54 PM UTCschwarzeAttached File-=>Added Lk-punct.patch, #40340

    Back to the top


    Powered by Savane 3.1-cleanup1