From e477618d40cb3db39667f06085c67cdfa33710a2 Mon Sep 17 00:00:00 2001 From: Nick Wellnhofer Date: Sun, 7 Jun 2015 17:33:25 +0200 Subject: Avoid strlen in xml.c --- src/xml.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src') diff --git a/src/xml.c b/src/xml.c index 688dd36..7eec5a6 100644 --- a/src/xml.c +++ b/src/xml.c @@ -13,12 +13,7 @@ static void escape_xml(cmark_strbuf *dest, const unsigned char *source, bufsize_t length) { - if (source != NULL) { - if (length < 0) - length = strlen((char *)source); - - houdini_escape_html0(dest, source, length, 0); - } + houdini_escape_html0(dest, source, length, 0); } struct render_state { -- cgit v1.2.3