dovecot-2.2-pigeonhole: doveadm-sieve: Made active script last_c...

pigeonhole at rename-it.nl pigeonhole at rename-it.nl
Sat Apr 20 00:21:43 EEST 2013


details:   http://hg.rename-it.nl/dovecot-2.2-pigeonhole/rev/2de5c020cc03
changeset: 1756:2de5c020cc03
user:      Stephan Bosch <stephan at rename-it.nl>
date:      Fri Apr 19 23:21:35 2013 +0200
description:
doveadm-sieve: Made active script last_change time always dependent on sieve_dir mtime.
Change is preliminary. Still doing some experiments, 'ping-pong' problem is not solved.

diffstat:

 src/lib-sievestorage/sieve-storage-save.c   |  2 ++
 src/lib-sievestorage/sieve-storage-script.c |  2 ++
 2 files changed, 4 insertions(+), 0 deletions(-)

diffs (31 lines):

diff -r 9f14740cc1c0 -r 2de5c020cc03 src/lib-sievestorage/sieve-storage-save.c
--- a/src/lib-sievestorage/sieve-storage-save.c	Fri Apr 19 22:26:32 2013 +0200
+++ b/src/lib-sievestorage/sieve-storage-save.c	Fri Apr 19 23:21:35 2013 +0200
@@ -416,6 +416,8 @@
 			sieve_storage_set_critical(storage,
 				"rename(%s, %s) failed: %m", str_c(temp_path), storage->active_path);
 		}
+	} else {
+		sieve_storage_mark_modified(storage);
 	}
 
 	(void)unlink(str_c(temp_path));
diff -r 9f14740cc1c0 -r 2de5c020cc03 src/lib-sievestorage/sieve-storage-script.c
--- a/src/lib-sievestorage/sieve-storage-script.c	Fri Apr 19 22:26:32 2013 +0200
+++ b/src/lib-sievestorage/sieve-storage-script.c	Fri Apr 19 23:21:35 2013 +0200
@@ -302,6 +302,7 @@
 {
 	struct stat st;
 
+#if 0
 	/* Try direct lstat first */
 	if (lstat(storage->active_path, &st) == 0) {
 		*last_change_r = st.st_mtime;
@@ -313,6 +314,7 @@
 		sieve_storage_set_critical(storage, "lstat(%s) failed: %m",
 			   storage->active_path);
 	}
+#endif
 
 	/* Fall back to statting storage directory */
 	return sieve_storage_get_last_change(storage, last_change_r);


More information about the dovecot-cvs mailing list