[dovecot-cvs] dovecot/src/lib-storage/list subscription-file.c, 1.3, 1.4

tss at dovecot.org tss at dovecot.org
Wed Feb 14 18:32:29 UTC 2007


Update of /var/lib/cvs/dovecot/src/lib-storage/list
In directory talvi:/tmp/cvs-serv30678/list

Modified Files:
	subscription-file.c 
Log Message:
fsync() subscriptions file and maildir-keywords before rename()ing them.



Index: subscription-file.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/list/subscription-file.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- subscription-file.c	16 Jan 2007 17:00:38 -0000	1.3
+++ subscription-file.c	14 Feb 2007 18:32:25 -0000	1.4
@@ -144,6 +144,11 @@
 		}
 	}
 
+	if (!failed && fsync(fd_out) < 0) {
+		subsfile_set_syscall_error(list, "fsync()", path);
+		failed = TRUE;
+	}
+
 	if (input != NULL)
 		i_stream_destroy(&input);
 	o_stream_destroy(&output);



More information about the dovecot-cvs mailing list