aboutsummaryrefslogtreecommitdiffstats
path: root/FICS
diff options
context:
space:
mode:
authorMarkus Uhlin <markus@nifty-networks.net>2024-04-01 21:44:43 +0200
committerMarkus Uhlin <markus@nifty-networks.net>2024-04-01 21:44:43 +0200
commitd140b0b025ac6a87dae391a3c1d45c4aab0a8cc5 (patch)
tree9fbee0e98ebb8a7baccf4fd7b04ec5af44d2c853 /FICS
parente140a8b3ad7130510f3a057a37a33b4ead93001f (diff)
Reformatted set_time()
Diffstat (limited to 'FICS')
-rw-r--r--FICS/variable.c25
1 files changed, 14 insertions, 11 deletions
diff --git a/FICS/variable.c b/FICS/variable.c
index 71a2c77..0eb82ca 100644
--- a/FICS/variable.c
+++ b/FICS/variable.c
@@ -352,19 +352,22 @@ PRIVATE int set_uscf(int p, char *var, char *val)
return VAR_OK;
}
*/
-PRIVATE int set_time(int p, char *var, char *val)
+
+PRIVATE int
+set_time(int p, char *var, char *val)
{
- int v = -1;
+ int v = -1;
- if (!val)
- return VAR_BADVAL;
- if (sscanf(val, "%d", &v) != 1)
- return VAR_BADVAL;
- if ((v < 0) || (v > 240))
- return VAR_BADVAL;
- parray[p].d_time = v;
- pprintf(p, "Default time set to %d.\n", v);
- return VAR_OK;
+ if (!val)
+ return VAR_BADVAL;
+ if (sscanf(val, "%d", &v) != 1)
+ return VAR_BADVAL;
+ if (v < 0 || v > 240)
+ return VAR_BADVAL;
+
+ parray[p].d_time = v;
+ pprintf(p, "Default time set to %d.\n", v);
+ return VAR_OK;
}
PRIVATE int