Skip to content

Commit

Permalink
> 32 nested balanced parens in a link is bananas (#48)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yuki Izumi authored Jul 12, 2017
1 parent 970e029 commit 298d9d2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/inlines.c
Original file line number Diff line number Diff line change
Expand Up @@ -871,6 +871,8 @@ static bufsize_t manual_scan_link_url(cmark_chunk *input, bufsize_t offset) {
else if (input->data[i] == '(') {
++nb_p;
++i;
if (nb_p > 32)
return -1;
} else if (input->data[i] == ')') {
if (nb_p == 0)
break;
Expand Down

0 comments on commit 298d9d2

Please sign in to comment.