summaryrefslogtreecommitdiffstats
path: root/sys/msdosfs
diff options
context:
space:
mode:
authorache <ache@FreeBSD.org>1996-04-05 16:31:49 +0000
committerache <ache@FreeBSD.org>1996-04-05 16:31:49 +0000
commita17e006b7fcf7be144bd50e12e4df45e94a8ea70 (patch)
tree32a7b62103a3f8ceb2cf0368e93ad50072425221 /sys/msdosfs
parent8d7c1b3d2ab53ea2a9ac2b2e8a00cf382ac98519 (diff)
downloadFreeBSD-src-a17e006b7fcf7be144bd50e12e4df45e94a8ea70.zip
FreeBSD-src-a17e006b7fcf7be144bd50e12e4df45e94a8ea70.tar.gz
Don't adjust file times for UTC clock to have the same timestamps
for DOS/FreeBSD.
Diffstat (limited to 'sys/msdosfs')
-rw-r--r--sys/msdosfs/msdosfs_conv.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/msdosfs/msdosfs_conv.c b/sys/msdosfs/msdosfs_conv.c
index d3b3c07..9d24f6f 100644
--- a/sys/msdosfs/msdosfs_conv.c
+++ b/sys/msdosfs/msdosfs_conv.c
@@ -1,4 +1,4 @@
-/* $Id: msdosfs_conv.c,v 1.6 1995/10/29 15:31:46 phk Exp $ */
+/* $Id: msdosfs_conv.c,v 1.7 1995/11/07 14:06:41 phk Exp $ */
/* $NetBSD: msdosfs_conv.c,v 1.6.2.1 1994/08/30 02:27:57 cgd Exp $ */
/*
@@ -77,8 +77,9 @@ unix2dostime(tsp, ddp, dtp)
* If the time from the last conversion is the same as now, then
* skip the computations and use the saved result.
*/
- t = tsp->ts_sec - (tz.tz_minuteswest * 60) - adjkerntz;
- /* +- daylight savings time correction */ ;
+ t = tsp->ts_sec - (tz.tz_minuteswest * 60)
+ - wall_cmos_clock ? adjkerntz : 0;
+ /* - daylight savings time correction */
if (lasttime != t) {
lasttime = t;
lastdtime = (((t % 60) >> 1) << DT_2SECONDS_SHIFT)
@@ -175,7 +176,8 @@ dos2unixtime(dd, dt, tsp)
lastseconds = (days * 24 * 60 * 60) + SECONDSTO1980;
}
tsp->ts_sec = seconds + lastseconds + (tz.tz_minuteswest * 60)
- + adjkerntz /* -+ daylight savings time correction */ ;
+ + wall_cmos_clock ? adjkerntz : 0;
+ /* + daylight savings time correction */
tsp->ts_nsec = 0;
}
OpenPOWER on IntegriCloud