Keep HTML comments in output

See https://spec.commonmark.org/0.29/#example-621
This commit is contained in:
Karl Bartel 2019-09-29 18:16:00 +02:00 committed by Enno Boland
parent 1793559632
commit a9636129cc

1
smu.c
View file

@ -148,6 +148,7 @@ docomment(const char *begin, const char *end, int newblock) {
p = strstr(begin, "-->");
if(!p || p + 3 >= end)
return 0;
fprintf(stdout, "%.*s\n", (int)(p + 3 - begin), begin);
return (p + 3 - begin) * (newblock ? -1 : 1);
}