diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-12-16 13:51:01 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-12-16 13:51:01 +0000 |
commit | d0e30c00d1e352f6dcae2a60d7270f8ba4a71d76 (patch) | |
tree | b63c6941c1b145752d8ef786f33244157deb4213 /sbin/fsdb | |
parent | 12cf882ebb84905c2a2505bedfa81af87876511a (diff) |
handle time_t things that really are not time_t
Diffstat (limited to 'sbin/fsdb')
-rw-r--r-- | sbin/fsdb/fsdbutil.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/sbin/fsdb/fsdbutil.c b/sbin/fsdb/fsdbutil.c index 8d064bca851..d71e25f1f7e 100644 --- a/sbin/fsdb/fsdbutil.c +++ b/sbin/fsdb/fsdbutil.c @@ -1,4 +1,4 @@ -/* $NetBSD: fsdbutil.c,v 1.2 1995/10/08 23:18:12 thorpej Exp $ */ +/* $NetBSD: fsdbutil.c,v 1.3 1995/12/14 22:30:45 thorpej Exp $ */ /* * Copyright (c) 1995 John T. Kohl @@ -29,7 +29,7 @@ */ #ifndef lint -static char rcsid[] = "$NetBSD: fsdbutil.c,v 1.2 1995/10/08 23:18:12 thorpej Exp $"; +static char rcsid[] = "$NetBSD: fsdbutil.c,v 1.3 1995/12/14 22:30:45 thorpej Exp $"; #endif /* not lint */ #include <sys/types.h> @@ -96,6 +96,7 @@ printstat(cp, inum, dp) { struct group *grp; struct passwd *pw; + time_t t; char *p; printf("%s: ", cp); @@ -130,13 +131,16 @@ printstat(cp, inum, dp) break; } printf("I=%lu MODE=%o SIZE=%qu", inum, dp->di_mode, dp->di_size); - p = ctime((time_t *)&dp->di_mtime); + t = dp->di_mtime; + p = ctime(&t); printf("\n\tMTIME=%15.15s %4.4s [%d nsec]", &p[4], &p[20], dp->di_mtimensec); - p = ctime((time_t *)&dp->di_ctime); + t = dp->di_ctime; + p = ctime(&t); printf("\n\tCTIME=%15.15s %4.4s [%d nsec]", &p[4], &p[20], dp->di_ctimensec); - p = ctime((time_t *)&dp->di_atime); + t = dp->di_atime; + p = ctime(&t); printf("\n\tATIME=%15.15s %4.4s [%d nsec]\n", &p[4], &p[20], dp->di_atimensec); |