diff options
author | John MacFarlane <jgm@berkeley.edu> | 2016-02-06 13:35:29 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2016-02-06 13:35:29 -0800 |
commit | 131b79f9fe0ef73af74f93d17d3c71abd9c29621 (patch) | |
tree | 18c7f01051a72f6a89605b6811b00da5ae204946 /src/blocks.c | |
parent | f5bcd71573aa11be4ffbf782907af3c51701e8da (diff) |
S_advance_offset: Only set partially_consumed_tab in columns mode.
Diffstat (limited to 'src/blocks.c')
-rw-r--r-- | src/blocks.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/blocks.c b/src/blocks.c index 53d0251..20ea579 100644 --- a/src/blocks.c +++ b/src/blocks.c @@ -587,7 +587,7 @@ static void S_advance_offset(cmark_parser *parser, cmark_chunk *input, while (count > 0 && (c = peek_at(input, parser->offset))) { if (c == '\t') { chars_to_tab = TAB_STOP - (parser->column % TAB_STOP); - parser->partially_consumed_tab = chars_to_tab > count; + parser->partially_consumed_tab = columns && chars_to_tab > count; chars_to_advance = parser->partially_consumed_tab ? count : chars_to_tab; parser->column += chars_to_advance; parser->offset += parser->partially_consumed_tab ? 0 : 1; |