From 4b669956d1ffbc4833dc74cc3791522c662a119e Mon Sep 17 00:00:00 2001 From: Beletti Date: Tue, 19 Nov 2013 01:30:55 +0000 Subject: [PATCH] commands/at: changed K&R to ANSI style Change-Id: Ifb12349bcf456ff303c15fdedda4ab853a148aff --- commands/at/at.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/commands/at/at.c b/commands/at/at.c index 6ca2d05d5..3442e28d9 100644 --- a/commands/at/at.c +++ b/commands/at/at.c @@ -23,9 +23,7 @@ int getltim(char *t); int getlday(char *m, char *d); int digitstring(char *s); -int main(argc, argv, envp) -int argc; -char **argv, **envp; +int main(int argc, char **argv, char **envp) { int i, c, mask, ltim, year, lday = NODAY; char buf[64], job[30], pastjob[35], *dp, *sp; @@ -173,8 +171,7 @@ char **argv, **envp; /*-------------------------------------------------------------------------* * getltim() return((time OK) ? daytime : -1) * *-------------------------------------------------------------------------*/ -int getltim(t) -char *t; +int getltim(char *t) { if (t[4] == '\0' && t[3] >= '0' && t[3] <= '9' && t[2] >= '0' && t[2] <= '5' && t[1] >= '0' && t[1] <= '9' && @@ -187,8 +184,7 @@ char *t; /*-------------------------------------------------------------------------* * getlday() return ((date OK) ? yearday : -1) * *-------------------------------------------------------------------------*/ -int getlday(m, d) -char *m, *d; +int getlday(char *m, char *d) { int i, day, im; static int cumday[] = {0, 0, 31, 60, 91, 121, 152, @@ -215,8 +211,7 @@ char *m, *d; -int digitstring(s) -char *s; +int digitstring(char *s) { while (*s >= '0' && *s <= '9') s++; return((*s == '\0') ? 1 : 0); -- 2.44.0