From 52cf41b6df67171ed301ce783d9744d4f5417c81 Mon Sep 17 00:00:00 2001 From: Markus Uhlin Date: Mon, 25 Dec 2023 17:57:14 +0100 Subject: Reformatted safestring() --- FICS/utils.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/FICS/utils.c b/FICS/utils.c index 4d20046..5aaca9b 100644 --- a/FICS/utils.c +++ b/FICS/utils.c @@ -512,17 +512,16 @@ PUBLIC int safechar(int c) return 1; } -PUBLIC int safestring(char *str) +PUBLIC int +safestring(char *str) { - int i; - - if (!str) - return 1; - for (i = 0; str[i]; i++) { - if (!safechar(str[i])) - return 0; - } - return 1; + if (!str) + return 1; + for (int i = 0; str[i]; i++) { + if (!safechar(str[i])) + return 0; + } + return 1; } PUBLIC int -- cgit v1.2.3