summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/cmark.h1
-rw-r--r--src/inlines.c5
2 files changed, 2 insertions, 4 deletions
diff --git a/src/cmark.h b/src/cmark.h
index e34df72..ff2f9a2 100644
--- a/src/cmark.h
+++ b/src/cmark.h
@@ -9,7 +9,6 @@
#define VERSION "0.1"
#define CODE_INDENT 4
-#define STACK_LIMIT 1000
struct node_inl {
enum {
diff --git a/src/inlines.c b/src/inlines.c
index 1ab1b29..a43012f 100644
--- a/src/inlines.c
+++ b/src/inlines.c
@@ -416,7 +416,7 @@ static node_inl* handle_strong_emph(subject* subj, unsigned char c, node_inl **l
cannotClose:
inl_text = make_str(chunk_dup(&subj->input, subj->pos - numdelims, numdelims));
- if (can_open && subj->emphasis_nestlevel < STACK_LIMIT)
+ if (can_open)
{
istack = (inline_stack*)malloc(sizeof(inline_stack));
if (istack == NULL) {
@@ -617,8 +617,7 @@ static int link_label(subject* subj, chunk *raw_label)
advance(subj); // advance past [
unsigned char c;
- while ((c = peek_char(subj)) &&
- (c != ']' || (nestlevel > 0 && nestlevel < STACK_LIMIT))) {
+ while ((c = peek_char(subj)) && (c != ']' || nestlevel > 0)) {
switch (c) {
case '`':
tmp = handle_backticks(subj);