[Top][All Lists]

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

[bug #64061] pdfpic.tmac uses sed badly and non-portably

From: G. Branden Robinson
Subject: [bug #64061] pdfpic.tmac uses sed badly and non-portably
Date: Mon, 17 Apr 2023 04:33:27 -0400 (EDT)


                 Summary: pdfpic.tmac uses sed badly and non-portably
                   Group: GNU roff
               Submitter: gbranden
               Submitted: Mon 17 Apr 2023 08:33:25 AM UTC
                Category: Macro - others/general
                Severity: 3 - Normal
              Item Group: Incorrect behaviour
                  Status: In Progress
                 Privacy: Public
             Assigned to: gbranden
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None


Follow-up Comments:

Date: Mon 17 Apr 2023 08:33:25 AM UTC By: G. Branden Robinson <gbranden>
Affects groff 1.22.4.

pdfpic.tmac has several problems.

1.  It unnecessarily uses double backslashes in a single-quoted sed
expression.  Since the roff escape character has been changed (to '@'), this
means that the doubled backslashes appear as-is to sed's input, and some seds
don't support this non-standard usage.

2.  It uses the sequence '\n' in the replacement part of a sed 's' command. 
This is non-standard and undefined on some seds.

3.  It wastefully uses grep to filter the output when sed is readily capable
of performing this task itself without the expense of launching a separate
process in the pipeline.

See [https://lists.gnu.org/archive/html/groff/2023-04/msg00149.html recent
discussion on the groff mailing list].


Reply to this item at:


Message sent via Savannah

reply via email to

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