URL:
<https://savannah.gnu.org/bugs/?65248>
Summary: [eqn] doesn't detect recursive macro definitions,
permitting infinite loops
Group: GNU roff
Submitter: gbranden
Submitted: Sun 04 Feb 2024 05:48:08 AM UTC
Category: Preprocessor eqn
Severity: 4 - Important
Item Group: Crash/Unresponsive
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
_______________________________________________________
Follow-up Comments:
-------------------------------------------------------
Date: Sun 04 Feb 2024 05:48:08 AM UTC By: G. Branden Robinson <gbranden>
Noticed by Ingo Schwarze
[https://cvsweb.bsd.lv/mandoc/eqn_parse.h?rev=1.4&content-type=text/x-cvsweb-markup&sortby=date
in _mandoc_ CVS].
.EQ
define inner "content"
define outer "inner outer"
outer
.EN
This endless loop was found by tb@ using afl(1).
Incidentally, GNU eqn(1) also performs an infinite loop in this
situation and then crashes when memory runs out, but that's not an
excuse for nasty behaviour of mandoc(1).
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?65248>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/