aboutsummaryrefslogtreecommitdiff
path: root/format.c
diff options
context:
space:
mode:
Diffstat (limited to 'format.c')
-rw-r--r--format.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/format.c b/format.c
index 84c634d..4f93b7b 100644
--- a/format.c
+++ b/format.c
@@ -459,6 +459,9 @@ xs_str *sanitize(const char *content)
char *p;
const char *v;
+ if (!content)
+ return NULL;
+
sl = xs_regex_split(content, "</?[^>]+>");
p = sl;