瀏覽代碼

html.c: invalid html tag: else? just show it as encoded text.

Signed-off-by: Yonle <yonle@lecturify.net>
Yonle 1 年之前
父節點
當前提交
7e40e0d783
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      format.c

+ 4 - 0
format.c

@@ -226,6 +226,10 @@ xs_str *sanitize(const char *content)
                     v[1] == '/' ? "/" : "", tag, xs_list_len(el) ? " " : "", s3);
 
                 s = xs_str_cat(s, s2);
+            } else {
+                /* else? just show it with encoded code.. that's it. */
+                xs *el = encode_html(v);
+                s = xs_str_cat(s, el);
             }
         }
         else {