From: Art Cancro Date: Wed, 24 Jan 2024 01:22:33 +0000 (-1000) Subject: Don't bother reading this commit. X-Git-Tag: v997~15 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=491081a15e7f711852a96cfb9396048b53a23a14 Don't bother reading this commit. --- diff --git a/webcit-ng/server/html2html.c b/webcit-ng/server/html2html.c index f04ddef7f..506a70de7 100644 --- a/webcit-ng/server/html2html.c +++ b/webcit-ng/server/html2html.c @@ -13,12 +13,14 @@ void stripquotes(char *s) { int len; - if (!s) + if (!s) { return; + } len = strlen(s); - if (len < 2) + if (len < 2) { return; + } if (((s[0] == '\"') && (s[len - 1] == '\"')) || ((s[0] == '\'') && (s[len - 1] == '\''))) { s[len - 1] = 0; @@ -36,19 +38,24 @@ void extract_charset_from_meta(char *charset, char *meta_http_equiv, char *meta_ char *ptr; char buf[64]; - if (!charset) + if (!charset) { return; - if (!meta_http_equiv) + } + if (!meta_http_equiv) { return; - if (!meta_content) + } + if (!meta_content) { return; + } - if (strcasecmp(meta_http_equiv, "Content-type")) + if (strcasecmp(meta_http_equiv, "Content-type")) { return; + } ptr = strchr(meta_content, ';'); - if (!ptr) + if (!ptr) { return; + } safestrncpy(buf, ++ptr, sizeof buf); string_trim(buf); @@ -65,8 +72,9 @@ void extract_charset_from_meta(char *charset, char *meta_http_equiv, char *meta_ } // Remove wandering punctuation - if ((ptr = strchr(charset, '\"'))) + if ((ptr = strchr(charset, '\"'))) { *ptr = 0; + } string_trim(charset); } }