mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-12-26 01:03:37 +00:00
Avoid too deep nesting of html_entry().
This commit is contained in:
parent
6e5c7d4a4b
commit
2700567fca
1 changed files with 4 additions and 0 deletions
4
html.c
4
html.c
|
@ -836,6 +836,10 @@ xs_str *html_entry(snac *snac, xs_str *os, const xs_dict *msg, int local,
|
|||
if (is_hidden(snac, id))
|
||||
return os;
|
||||
|
||||
/* avoid too deep nesting, as it may be a loop */
|
||||
if (level >= 256)
|
||||
return os;
|
||||
|
||||
xs *s = xs_str_new("<div>\n");
|
||||
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue