From 533aa54353bcbfc4d972b69b5028b5b0974a7ac0 Mon Sep 17 00:00:00 2001 From: ed Date: Sat, 13 Mar 2010 18:06:17 +0000 Subject: [PATCH] Small style(9) cleanups. --- lib/libcompat/4.1/ascftime.c | 3 ++- lib/libcompat/4.1/cftime.c | 3 ++- lib/libcompat/4.1/ftime.c | 3 +-- lib/libcompat/4.1/getpw.c | 13 +++++++------ lib/libcompat/4.3/cfree.c | 1 + 5 files changed, 13 insertions(+), 10 deletions(-) diff --git a/lib/libcompat/4.1/ascftime.c b/lib/libcompat/4.1/ascftime.c index b3c15e43f32..cfb90afd5d8 100644 --- a/lib/libcompat/4.1/ascftime.c +++ b/lib/libcompat/4.1/ascftime.c @@ -41,5 +41,6 @@ int ascftime(char *s, const char *format, const struct tm *tmptr) { - return strftime(s, MAXLEN, format? format: "%C", tmptr); + + return (strftime(s, MAXLEN, format? format: "%C", tmptr)); } diff --git a/lib/libcompat/4.1/cftime.c b/lib/libcompat/4.1/cftime.c index 8033e446eb9..41275b669b7 100644 --- a/lib/libcompat/4.1/cftime.c +++ b/lib/libcompat/4.1/cftime.c @@ -41,6 +41,7 @@ int cftime(char *s, char *format, const time_t *clock) { - return strftime(s, MAXLEN, format? format: "%C", localtime(clock)); + + return (strftime(s, MAXLEN, format? format: "%C", localtime(clock))); } diff --git a/lib/libcompat/4.1/ftime.c b/lib/libcompat/4.1/ftime.c index cc4a7f9ca07..e7be278dce8 100644 --- a/lib/libcompat/4.1/ftime.c +++ b/lib/libcompat/4.1/ftime.c @@ -37,8 +37,7 @@ static char rcsid[] = "$FreeBSD$"; #include int -ftime(tbp) - struct timeb *tbp; +ftime(struct timeb *tbp) { struct timezone tz; struct timeval t; diff --git a/lib/libcompat/4.1/getpw.c b/lib/libcompat/4.1/getpw.c index d6f4f8b5c21..7c66c8f4afb 100644 --- a/lib/libcompat/4.1/getpw.c +++ b/lib/libcompat/4.1/getpw.c @@ -40,13 +40,14 @@ int getpw(uid_t uid, char *buf) { - struct passwd *pw; + struct passwd *pw; - pw = getpwuid(uid); - endpwent(); + pw = getpwuid(uid); + endpwent(); - if(pw == 0) return -1; + if (pw == 0) + return (-1); - strncpy(buf, pw->pw_name, L_cuserid); - return 0; + strncpy(buf, pw->pw_name, L_cuserid); + return (0); } diff --git a/lib/libcompat/4.3/cfree.c b/lib/libcompat/4.3/cfree.c index ca51d2e9594..7a7baadb6bc 100644 --- a/lib/libcompat/4.3/cfree.c +++ b/lib/libcompat/4.3/cfree.c @@ -39,5 +39,6 @@ static char sccsid[] = "@(#)cfree.c 8.1 (Berkeley) 6/4/93"; void cfree(void *p) { + free(p); } -- 2.45.2