Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/stat Improve previous with comments.



details:   https://anonhg.NetBSD.org/src/rev/43c05078c01b
branches:  trunk
changeset: 759025:43c05078c01b
user:      dholland <dholland%NetBSD.org@localhost>
date:      Thu Nov 25 04:33:30 2010 +0000

description:
Improve previous with comments.

diffstat:

 usr.bin/stat/stat.c |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (35 lines):

diff -r f06e8bc052da -r 43c05078c01b usr.bin/stat/stat.c
--- a/usr.bin/stat/stat.c       Wed Nov 24 22:57:53 2010 +0000
+++ b/usr.bin/stat/stat.c       Thu Nov 25 04:33:30 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: stat.c,v 1.29 2010/11/24 22:57:53 dholland Exp $ */
+/*     $NetBSD: stat.c,v 1.30 2010/11/25 04:33:30 dholland Exp $ */
 
 /*
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
 
 #include <sys/cdefs.h>
 #if !defined(lint)
-__RCSID("$NetBSD: stat.c,v 1.29 2010/11/24 22:57:53 dholland Exp $");
+__RCSID("$NetBSD: stat.c,v 1.30 2010/11/25 04:33:30 dholland Exp $");
 #endif
 
 #if ! HAVE_NBTOOL_CONFIG_H
@@ -1013,6 +1013,7 @@
                        (void)snprintf(tmp, sizeof(tmp), "%d", size);
                        (void)strcat(lfmt, tmp);
                }
+               /* Seconds: time_t cast to long long. */
                (void)strcat(lfmt, "lld");
 
                /*
@@ -1024,6 +1025,8 @@
                /*
                 * We can "print" at most nine digits of precision.  The
                 * rest we will pad on at the end.
+                *
+                * Nanoseconds: long.
                 */
                (void)snprintf(tmp, sizeof(tmp), "%dld", prec > 9 ? 9 : prec);
                (void)strcat(lfmt, tmp);



Home | Main Index | Thread Index | Old Index