aboutsummaryrefslogtreecommitdiffstats
path: root/FICS/utils.c
diff options
context:
space:
mode:
authorMarkus Uhlin <markus@nifty-networks.net>2023-12-25 17:57:14 +0100
committerMarkus Uhlin <markus@nifty-networks.net>2023-12-25 17:57:14 +0100
commit52cf41b6df67171ed301ce783d9744d4f5417c81 (patch)
tree5304a55f617ba8d1294d210301bbfaa397b210f6 /FICS/utils.c
parent0a0c42691503f7a516994632522027e5793b4935 (diff)
Reformatted safestring()
Diffstat (limited to 'FICS/utils.c')
-rw-r--r--FICS/utils.c19
1 files 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