rpms/dosfstools/F-10 dosfstools-vfat-timingfix.diff, NONE, 1.1 dosfstools.spec, 1.32, 1.33
Tom Callaway
spot at fedoraproject.org
Mon Nov 17 22:01:54 UTC 2008
Author: spot
Update of /cvs/pkgs/rpms/dosfstools/F-10
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv17265/F-10
Modified Files:
dosfstools.spec
Added Files:
dosfstools-vfat-timingfix.diff
Log Message:
fix vfat timing bug (bz 448247)
dosfstools-vfat-timingfix.diff:
--- NEW FILE dosfstools-vfat-timingfix.diff ---
diff -ru dosfstools-3.0.0/src/mkdosfs.c dosfstools-3.0.0-new/src/mkdosfs.c
--- dosfstools-3.0.0/src/mkdosfs.c 2008-09-28 05:22:09.000000000 -0400
+++ dosfstools-3.0.0-new/src/mkdosfs.c 2008-11-04 12:40:28.000000000 -0500
@@ -57,6 +57,7 @@
#include <stdlib.h>
#include <sys/ioctl.h>
#include <sys/stat.h>
+#include <sys/time.h>
#include <sys/types.h>
#include <unistd.h>
#include <time.h>
@@ -283,6 +284,7 @@
static int verbose = 0; /* Default to verbose mode off */
static long volume_id; /* Volume ID number */
static time_t create_time; /* Creation time */
+static struct timeval create_timeval; /* Creation time */
static char volume_name[] = " "; /* Volume name */
static unsigned long long blocks; /* Number of blocks in filesystem */
static int sector_size = 512; /* Size of a logical sector */
@@ -1427,8 +1429,9 @@
program_name = p+1;
}
- time(&create_time);
- volume_id = (long)create_time; /* Default volume ID = creation time */
+ gettimeofday(&create_timeval, NULL);
+ create_time = create_timeval.tv_sec;
+ volume_id = (u_int32_t)( (create_timeval.tv_sec << 20) | create_timeval.tv_usec ); /* Default volume ID = creation time, fudged for more uniqueness */
check_atari();
printf ("%s " VERSION " (" VERSION_DATE ")\n",
Index: dosfstools.spec
===================================================================
RCS file: /cvs/pkgs/rpms/dosfstools/F-10/dosfstools.spec,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- dosfstools.spec 30 Sep 2008 14:55:52 -0000 1.32
+++ dosfstools.spec 17 Nov 2008 22:01:24 -0000 1.33
@@ -1,10 +1,11 @@
Name: dosfstools
Summary: Utilities for making and checking MS-DOS FAT filesystems on Linux
Version: 3.0.0
-Release: 1%{?dist}
+Release: 2%{?dist}
License: GPLv3+
Group: Applications/System
-Source: http://www.daniel-baumann.ch/software/dosfstools/%{name}-%{version}.tar.bz2
+Source0: http://www.daniel-baumann.ch/software/dosfstools/%{name}-%{version}.tar.bz2
+Patch0: dosfstools-vfat-timingfix.diff
URL: http://www.daniel-baumann.ch/software/dosfstools/
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Obsoletes: mkdosfs-ygg
@@ -17,6 +18,7 @@
%prep
%setup -q
+%patch0 -p1 -b .vfat-timingfix
%build
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
@@ -35,6 +37,9 @@
%{_mandir}/man8/*
%changelog
+* Mon Nov 17 2008 Tom "spot" Callaway <tcallawa at redhat.com> - 3.0.0-2
+- apply vfat timing fix
+
* Tue Sep 30 2008 Tom "spot" Callaway <tcallawa at redhat.com> - 3.0.0-1
- update to 3.0.0
More information about the fedora-extras-commits
mailing list