From: Art Cancro Date: Wed, 20 Dec 2023 15:50:53 +0000 (-0500) Subject: Found a place where 1TBS was not used, and fixed it. X-Git-Tag: v997~64 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=9156c9b8457a956712b129de23f35a607c2cb0ec Found a place where 1TBS was not used, and fixed it. 1TBS is important. People who do not use 1TBS are literally Hitler. --- diff --git a/webcit-ng/server/util.c b/webcit-ng/server/util.c index e14dcd2e4..dc51ab3ba 100644 --- a/webcit-ng/server/util.c +++ b/webcit-ng/server/util.c @@ -21,10 +21,11 @@ int unescape_input(char *buf) { a = 0; while (a < buflen) { - if (buf[a] == '+') + if (buf[a] == '+') { buf[a] = ' '; + } if (buf[a] == '%') { - // don't let % chars through, rather truncate the input. + // don't let % chars through - instead truncate the input. if (a + 2 > buflen) { buf[a] = '\0'; buflen = a; @@ -37,9 +38,9 @@ int unescape_input(char *buf) { b = decode_hex(hex); buf[a] = (char) b; len = buflen - a - 2; - if (len > 0) + if (len > 0) { memmove(&buf[a + 1], &buf[a + 3], len); - + } buflen -= 2; } }