[metapost] segfault on incorrect input

luigi scarso luigi.scarso at gmail.com
Sat May 1 16:45:40 CEST 2021


On Sat, May 1, 2021 at 4:19 PM Hans Hagen <j.hagen at xs4all.nl> wrote:

> On 5/1/2021 9:46 AM, Martin Budaj wrote:
> > Hi,
> >
> > incidentally I've found that metapost segfaults on the following
> > (incorrect) input:
> >
> > nonstopmode;
> > % erroneously, a-b written instead of a_b
> > def a-b = a-c enddef;
> > a-b;
> > end
> >
> > The output is:
> >
> > l.4 def a-
> >            b = a-c enddef;
> > Segmentation fault
> >
> > Tested on 2.00 (TeX Live 2020/Debian) and 2.01 (TeX Live 2021/W32TeX).
> >
> > Metafont processes the file as expected, with a regular error message.
> Luigi,
>
> It also crashes in luatex but not in luametatex so it might be somewhere
> in the input buffer or error reporting part as that's done differently.
>
> b = a-c enddef; a-b; ;
>
> The bit after the ; is not seen in the crash.
>
> Hans
>

ok, I check.

-- 
luigi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/metapost/attachments/20210501/500f36c9/attachment.html>


More information about the metapost mailing list.