瀏覽代碼

why would somebody manipulate an expired message? right, he wouldn't:
he would either expunge the mailbox or configure his MUA to hide trashed
messages. consequently don't sync expired message flags, let alone
interpret them in a special way.
one special feature remains, though: if a non-expunged expired message
is flagged on the master, it will be unexpired on the slave. i'm not
sure whether i should remove or document this feature.

Oswald Buddenhagen 19 年之前
父節點
當前提交
4dc23fee7b
共有 1 個文件被更改,包括 5 次插入6 次删除
  1. 5 6
      src/sync.c

+ 5 - 6
src/sync.c

@@ -332,16 +332,15 @@ sync_old( int tops, store_t *sctx, store_t *tctx, store_conf_t *tconf, FILE *jfp
 			unex = 0;
 			if (srec->status & S_EXPIRED) {
 				if (!pull) {
-					if (sflags & F_DELETED) {
-						if (!(sflags & F_FLAGGED))
-							aflags &= ~F_DELETED;
-					} else
-						unex = 1;
+					if (aflags || dflags)
+						info( "Info: Flags of expired message changed in (%d,%d)\n", srec->muid, srec->suid );
+					return SYNC_OK;
 				} else {
 					if ((sflags & F_FLAGGED) && !(sflags & F_DELETED)) {
 						unex = 1;
 						dflags |= F_DELETED;
-					}
+					} else
+						return SYNC_OK;
 				}
 			}
 			rflags = (*nflags | aflags) & ~dflags;