Skip to content

Commit 4cc5541

Browse files
authored
fix: Use 'written_footnote_ix' (index) in place of named tag in subsequent references
1 parent 1f30fbb commit 4cc5541

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/html.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ static bool S_put_footnote_backref(cmark_html_renderer *renderer, cmark_strbuf *
6565
renderer->written_footnote_ix = renderer->footnote_ix;
6666
char m[32];
6767
snprintf(m, sizeof(m), "%d", renderer->written_footnote_ix);
68-
68+
6969
cmark_strbuf_puts(html, "<a href=\"#fnref-");
7070
houdini_escape_href(html, node->as.literal.data, node->as.literal.len);
7171
cmark_strbuf_puts(html, "\" class=\"footnote-backref\" data-footnote-backref aria-label=\"Back to reference ");
@@ -83,7 +83,7 @@ static bool S_put_footnote_backref(cmark_html_renderer *renderer, cmark_strbuf *
8383
cmark_strbuf_puts(html, "-");
8484
cmark_strbuf_puts(html, n);
8585
cmark_strbuf_puts(html, "\" class=\"footnote-backref\" data-footnote-backref aria-label=\"Back to reference ");
86-
houdini_escape_href(html, node->as.literal.data, node->as.literal.len);
86+
cmark_strbuf_puts(html, m);
8787
cmark_strbuf_puts(html, "-");
8888
cmark_strbuf_puts(html, n);
8989
cmark_strbuf_puts(html, "\">↩<sup class=\"footnote-ref\">");

0 commit comments

Comments
 (0)