Author :
Martin Mitáš
Date :
2024-02-07 11:44:39
Hash :aa53f82c Message :Introduce an overall limit to link. ref. defs instantiations.
This is to prevent time and output size explosion in case of input
pattern generated by this:
$ python -c 'N=1000; print("[x]: " + "x" * N + "\n[x]" * N)'
We roughly allow to blowing up the input size of the document
16 times by link reference definitions or up to 1 MB, whatever is
smaller. When the threshold is reached, following reference definitions
are sent to output unresolved as a text.
Fixes #238.