fix dropping of pending message propagations when resuming

started message propagations will now complete upon resumption even if
the run was requested to be a no-op - whether that's a good thing can
be argued, but it's the least effort way to avoid that committing
discards transaction state.
This commit is contained in:
Oswald Buddenhagen 2022-06-01 20:30:13 +02:00
parent e6c6840651
commit 03d0ab0fbf

View File

@ -737,11 +737,13 @@ box_opened2( sync_vars_t *svars, int t )
if (srec->status & S_PURGE) { if (srec->status & S_PURGE) {
t = srec->uid[F] ? F : N; t = srec->uid[F] ? F : N;
opts[t] |= OPEN_SETFLAGS; opts[t] |= OPEN_SETFLAGS;
} } else if (srec->status & S_PENDING) {
if (srec->status & S_UPGRADE) {
t = !srec->uid[F] ? F : N; t = !srec->uid[F] ? F : N;
opts[t] |= OPEN_APPEND; opts[t] |= OPEN_APPEND;
if (srec->status & S_UPGRADE)
opts[t^1] |= OPEN_OLD; opts[t^1] |= OPEN_OLD;
else
opts[t^1] |= OPEN_NEW;
if (chan->ops[t] & OP_EXPUNGE) // Don't propagate doomed msgs if (chan->ops[t] & OP_EXPUNGE) // Don't propagate doomed msgs
opts[t^1] |= OPEN_FLAGS; opts[t^1] |= OPEN_FLAGS;
} }