From 64a2ba46f67c89356917cacde12443d0fa7901f6 Mon Sep 17 00:00:00 2001
From: Steve French <stfrench@microsoft.com>
Date: Tue, 2 Apr 2019 18:20:07 -0500
Subject: [PATCH] smbinfo: snapshots are returned in gmt time so don't convert
timezone
We display snapshot times in GMT time, but need to convert them
to DCE time (SMB time format) without changing the time zone.
Signed-off-by: Steve French <stfrench@microsoft.com>
---
smbinfo.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -1009,7 +1009,7 @@ static void print_snapshots(struct smb_snapshot_array *psnap)
unsigned long long dce_time;
j = 0;
strptime(gmt_token, GMT_FORMAT, &tm);
- dce_time = mktime(&tm) * 10000000 + NTFS_TIME_OFFSET;
+ dce_time = timegm(&tm) * 10000000 + NTFS_TIME_OFFSET;
printf("\n SMB3:%lld ", dce_time);
}
}
--
2.17.1