[Pkg-shadow-commits] r2572 - in upstream/trunk: . lib
nekral-guest at alioth.debian.org
nekral-guest at alioth.debian.org
Sat Mar 21 19:12:01 UTC 2009
Author: nekral-guest
Date: 2009-03-21 19:12:00 +0000 (Sat, 21 Mar 2009)
New Revision: 2572
Modified:
upstream/trunk/ChangeLog
upstream/trunk/lib/commonio.c
Log:
* lib/commonio.c: Call fsync before closing the backup file. This
ensures that the backup file is flushed to the storage medium.
Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog 2009-03-18 21:22:22 UTC (rev 2571)
+++ upstream/trunk/ChangeLog 2009-03-21 19:12:00 UTC (rev 2572)
@@ -1,3 +1,8 @@
+2009-03-21 Nicolas François <nicolas.francois at centraliens.net>
+
+ * lib/commonio.c: Call fsync before closing the backup file. This
+ ensures that the backup file is flushed to the storage medium.
+
2009-03-15 Nicolas François <nicolas.francois at centraliens.net>
* src/groupmod.c: Embed gshadow related cleanup in #ifdef
Modified: upstream/trunk/lib/commonio.c
===================================================================
--- upstream/trunk/lib/commonio.c 2009-03-18 21:22:22 UTC (rev 2571)
+++ upstream/trunk/lib/commonio.c 2009-03-21 19:12:00 UTC (rev 2572)
@@ -251,7 +251,8 @@
fclose (bkfp);
return -1;
}
- if (fclose (bkfp) != 0) {
+ if ( (fsync (fileno (bkfp)) != 0)
+ || (fclose (bkfp) != 0)) {
return -1;
}
More information about the Pkg-shadow-commits
mailing list