summaryrefslogtreecommitdiff
path: root/usr.sbin/makefs/msdos
diff options
context:
space:
mode:
authorcheloha <cheloha@cvs.openbsd.org>2019-09-04 14:40:23 +0000
committercheloha <cheloha@cvs.openbsd.org>2019-09-04 14:40:23 +0000
commit98ee6e64e3403c7162aa0624d7356725906bb329 (patch)
treef551133d488fd405c97cd3f3811625e80e0e047b /usr.sbin/makefs/msdos
parentd19c4b188f7a7219434e44790ed652224571d772 (diff)
msdosfs: remove timezone support
This support is undocumented, only works if you're using the kernel timezone, and breaks during a DST shift. It also preferences file systems managed by a Windows installation: many implementations, like ours, use UTC by default (think: phones, digital cameras). No complaints on tech@. "good riddance" tedu@, "Yep." deraadt@
Diffstat (limited to 'usr.sbin/makefs/msdos')
-rw-r--r--usr.sbin/makefs/msdos/msdosfs_vfsops.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/usr.sbin/makefs/msdos/msdosfs_vfsops.c b/usr.sbin/makefs/msdos/msdosfs_vfsops.c
index 4af65f5fe63..91032db91ab 100644
--- a/usr.sbin/makefs/msdos/msdosfs_vfsops.c
+++ b/usr.sbin/makefs/msdos/msdosfs_vfsops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: msdosfs_vfsops.c,v 1.11 2016/12/17 16:43:30 krw Exp $ */
+/* $OpenBSD: msdosfs_vfsops.c,v 1.12 2019/09/04 14:40:22 cheloha Exp $ */
/*-
* Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.
@@ -48,7 +48,6 @@
*/
#include <sys/param.h>
-#include <sys/time.h>
#include "ffs/buf.h"
@@ -87,7 +86,6 @@ msdosfs_mount(struct mkfsvnode *devvp, int flags)
uint8_t SecPerClust;
int ronly = 0, error;
int bsize;
- struct timezone tz;
unsigned secsize = 512;
DPRINTF(("%s(bread 0)\n", __func__));
@@ -125,12 +123,7 @@ msdosfs_mount(struct mkfsvnode *devvp, int flags)
pmp->pm_SecPerTrack = getushort(b50->bpbSecPerTrack);
pmp->pm_Heads = getushort(b50->bpbHeads);
pmp->pm_Media = b50->bpbMedia;
-
- if (gettimeofday(NULL, &tz) == -1) {
- error = errno;
- goto error_exit;
- }
- pmp->pm_minuteswest = tz.tz_minuteswest;
+ pmp->pm_minuteswest = 0;
DPRINTF(("%s(BytesPerSec=%u, ResSectors=%u, FATs=%d, RootDirEnts=%u, "
"Sectors=%u, FATsecs=%lu, SecPerTrack=%u, Heads=%u, Media=%u)\n",