commit eab4a12a632b14436a4c595676a921fdc0d17319 Author: Oswald Buddenhagen <o...@users.sf.net> Date: Thu Apr 14 14:30:25 2022 +0200
make sure that entries with deleted placeholders are pruned we need to copy the S_DEL status bits when upgrading sync entries, so that when a placeholder is flagged at the same time for both deletion and upgrade, the entry pruning loop sees that the dummy message got expunged. note that we don't mask any bits, so the post-split entries may end up with S_DEL for a zero UID - which doesn't matter. src/sync_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sync_state.c b/src/sync_state.c index 32d1eab9..9130b3d7 100644 --- a/src/sync_state.c +++ b/src/sync_state.c @@ -615,7 +615,7 @@ upgrade_srec( sync_vars_t *svars, sync_rec_t *srec, int t ) // Mark the original entry for upgrade. srec->status = (srec->status & ~(S_DUMMY(F) | S_DUMMY(N))) | S_PENDING | S_UPGRADE; // Mark the placeholder for nuking. - nsrec->status = S_PURGE; + nsrec->status = S_PURGE | (srec->status & (S_DEL(F) | S_DEL(N))); nsrec->aflags[t] = F_DELETED; return nsrec; } _______________________________________________ isync-devel mailing list isync-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/isync-devel