From de986bafd7d765e94059c0e88df93a352d85d7aa Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Sat, 5 Mar 2016 19:39:45 +0100 Subject: content-parser: fixed a bug in previous patch --- src/content-parser.c | 3 +++ tests/check_content_parser.c | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/content-parser.c b/src/content-parser.c index f5e3aec..e636636 100644 --- a/src/content-parser.c +++ b/src/content-parser.c @@ -374,6 +374,9 @@ blogc_content_parse_inline(const char *src) current += 1; } } + else { + sb_string_append_c(rv, c); + } break; case '&': diff --git a/tests/check_content_parser.c b/tests/check_content_parser.c index bc21317..d9d2528 100644 --- a/tests/check_content_parser.c +++ b/tests/check_content_parser.c @@ -117,7 +117,7 @@ test_content_parse(void **state) "yay\n" "\n" "**bola**\n" - "-- foo\n" + "-- foo-bar\n" "--- bar\n" "\n" "-- asd\n" @@ -157,7 +157,7 @@ test_content_parse(void **state) "

guda\n" "yay

\n" "

bola\n" - "— foo\n" + "— foo-bar\n" "– bar

\n" "

— asd

\n" "

– lol

\n"); @@ -205,7 +205,7 @@ test_content_parse_crlf(void **state) "yay\r\n" "\r\n" "**bola**\r\n" - "-- foo\r\n" + "-- foo-bar\r\n" "--- bar\r\n" "\r\n" "-- asd\r\n" @@ -245,7 +245,7 @@ test_content_parse_crlf(void **state) "

guda\r\n" "yay

\r\n" "

bola\r\n" - "— foo\r\n" + "— foo-bar\r\n" "– bar

\r\n" "

— asd

\r\n" "

– lol

\r\n"); -- cgit v1.2.3-18-g5258