From owner-svn-src-all@FreeBSD.ORG Mon Oct 20 17:07:50 2008 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B9C691065670; Mon, 20 Oct 2008 17:07:50 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A77CB8FC1E; Mon, 20 Oct 2008 17:07:50 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id m9KH7oUZ076101; Mon, 20 Oct 2008 17:07:50 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id m9KH7onr076100; Mon, 20 Oct 2008 17:07:50 GMT (envelope-from des@svn.freebsd.org) Message-Id: <200810201707.m9KH7onr076100@svn.freebsd.org> From: Dag-Erling Smorgrav Date: Mon, 20 Oct 2008 17:07:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r184086 - head/lib/libutil X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Oct 2008 17:07:50 -0000 Author: des Date: Mon Oct 20 17:07:50 2008 New Revision: 184086 URL: http://svn.freebsd.org/changeset/base/184086 Log: Style and whitespace Modified: head/lib/libutil/login_times.c Modified: head/lib/libutil/login_times.c ============================================================================== --- head/lib/libutil/login_times.c Mon Oct 20 17:04:57 2008 (r184085) +++ head/lib/libutil/login_times.c Mon Oct 20 17:07:50 2008 (r184086) @@ -34,8 +34,8 @@ __FBSDID("$FreeBSD$"); static struct { const char *dw; - u_char cn; - u_char fl; + u_char cn; + u_char fl; } dws[] = { { "su", 2, LTM_SUN }, { "mo", 2, LTM_MON }, { "tu", 2, LTM_TUE }, @@ -54,22 +54,22 @@ parse_time(char * ptr, u_short * t) *t = (u_short)((val / 100) * 60 + (val % 100)); - return ptr; + return (ptr); } login_time_t -parse_lt(const char * str) +parse_lt(const char *str) { login_time_t t; memset(&t, 0, sizeof t); t.lt_dow = LTM_NONE; if (str && *str && strcmp(str, "Never") != 0 && strcmp(str, "None") != 0) { - int i; - login_time_t m = t; + int i; + login_time_t m = t; char *p; - char buf[64]; + char buf[64]; /* Make local copy and force lowercase to simplify parsing */ strlcpy(buf, str, sizeof buf); @@ -102,12 +102,12 @@ parse_lt(const char * str) t = m; } - return t; + return (t); } int -in_ltm(const login_time_t * ltm, struct tm * tt, time_t * ends) +in_ltm(const login_time_t *ltm, struct tm *tt, time_t *ends) { int rc = 0; @@ -130,31 +130,31 @@ in_ltm(const login_time_t * ltm, struct } } } - return rc; + return (rc); } int -in_lt(const login_time_t * ltm, time_t * t) +in_lt(const login_time_t *ltm, time_t *t) { - return in_ltm(ltm, localtime(t), t); + return (in_ltm(ltm, localtime(t), t)); } int -in_ltms(const login_time_t * ltm, struct tm * tm, time_t * t) +in_ltms(const login_time_t *ltm, struct tm * tm, time_t *t) { int i = 0; while (i < LC_MAXTIMES && ltm[i].lt_dow != LTM_NONE) { if (in_ltm(ltm + i, tm, t)) - return i; + return (i); i++; } - return -1; + return (-1); } int -in_lts(const login_time_t * ltm, time_t * t) +in_lts(const login_time_t *ltm, time_t *t) { - return in_ltms(ltm, localtime(t), t); + return (in_ltms(ltm, localtime(t), t)); }