bug-groff
[Top][All Lists]
Advanced

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

[bug #24048] [mm] infinite loop with certain page lengths


From: G. Branden Robinson
Subject: [bug #24048] [mm] infinite loop with certain page lengths
Date: Sat, 17 Jul 2021 17:38:46 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0

Follow-up Comment #4, bug #24048 (project groff):

I get two distinct backtrace patterns.

For the PL < 1.3i case I'm wondering if we shouldn't just have the macro
package give up and refuse to work for such a short length.  At that size
you're not formatting a document, you're formatting a business card (or,
really, a postage stamp) or something like that, and mm just was not designed
for that.

Anyway the problem in that case is a simple recursive trap.


troff: backtrace: '/.../../contrib/mm/m.tmac':1151: string 'pg*header'
troff: backtrace: '/.../../contrib/mm/m.tmac':1279: trap-called macro
'pg@header'
troff: backtrace: '/.../../contrib/mm/m.tmac':1283: trap-called macro
'pg@header'
[many repeats]
troff: backtrace: '/.../../contrib/mm/m.tmac':1283: trap-called macro
'pg@header'
troff: backtrace: 'smaller-test.mm':2   
troff: backtrace: file 'smaller-test.mm':2
troff: smaller-test.mm:2: fatal error: input stack limit exceeded (probable
infinite loop)


I note the above for completeness.  The 10.3i and 10.4i case is more
interesting, with the headers and footers calling into each other.


troff: backtrace: '/.../../contrib/mm/m.tmac':2019: macro
'ds@print-this-page'
troff: backtrace: '/.../../contrib/mm/m.tmac':1952: macro 'df@print-float'
troff: backtrace: '/.../../contrib/mm/m.tmac':1306: trap-called macro
'pg@header'
troff: backtrace: '/.../../contrib/mm/m.tmac':1324: trap-called macro
'pg@footer'
troff: backtrace: '/.../../contrib/mm/m.tmac':1370: macro 'pg@print-footer'
troff: backtrace: '/.../../contrib/mm/m.tmac':1331: trap-called macro
'pg@footer'
[the above 2 lines repeat]
troff: backtrace: '/.../../contrib/mm/m.tmac':1331: trap-called macro
'pg@footer'
troff: backtrace: file 'smaller-test.mm':6
troff: smaller-test.mm:6: fatal error: input stack limit exceeded (probable
infinite loop)




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?24048>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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