From dc698bb038756a926aaa529bda1b939eab2c1676 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Sat, 9 Jan 2010 19:10:49 +0100 Subject: *: make it easier to distinquish "struct tm", pointer to one, etc Signed-off-by: Denys Vlasenko --- util-linux/mkfs_vfat.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'util-linux/mkfs_vfat.c') diff --git a/util-linux/mkfs_vfat.c b/util-linux/mkfs_vfat.c index e794b3145..54c068d0b 100644 --- a/util-linux/mkfs_vfat.c +++ b/util-linux/mkfs_vfat.c @@ -538,16 +538,16 @@ int mkfs_vfat_main(int argc UNUSED_PARAM, char **argv) // create dir entry for volume_label struct msdos_dir_entry *de; #if 0 - struct tm tm; + struct tm tm_time; uint16_t t, d; #endif de = (void*)buf; strncpy(de->name, volume_label, sizeof(de->name)); STORE_LE(de->attr, ATTR_VOLUME); #if 0 - localtime_r(&create_time, &tm); - t = (tm.tm_sec >> 1) + (tm.tm_min << 5) + (tm.tm_hour << 11); - d = tm.tm_mday + ((tm.tm_mon+1) << 5) + ((tm.tm_year-80) << 9); + localtime_r(&create_time, &tm_time); + t = (tm_time.tm_sec >> 1) + (tm_time.tm_min << 5) + (tm_time.tm_hour << 11); + d = tm_time.tm_mday + ((tm_time.tm_mon+1) << 5) + ((tm_time.tm_year-80) << 9); STORE_LE(de->time, t); STORE_LE(de->date, d); //STORE_LE(de->ctime_cs, 0); -- cgit v1.2.3