diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-26 10:32:01 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-26 10:32:01 +0000 |
commit | 21103af131d3308ef39ad30c66e0fa0ea87b4525 (patch) | |
tree | 1f5669b5b37a04d2d2a6becc2056c5d341d4ab16 /pigeonhole/src | |
parent | Adding upstream version 1:2.3.21+dfsg1. (diff) | |
download | dovecot-21103af131d3308ef39ad30c66e0fa0ea87b4525.tar.xz dovecot-21103af131d3308ef39ad30c66e0fa0ea87b4525.zip |
Adding upstream version 1:2.3.21.1+dfsg1.upstream/1%2.3.21.1+dfsg1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'pigeonhole/src')
-rw-r--r-- | pigeonhole/src/lib-sieve/sieve-result.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/pigeonhole/src/lib-sieve/sieve-result.c b/pigeonhole/src/lib-sieve/sieve-result.c index 89d249e..be31cab 100644 --- a/pigeonhole/src/lib-sieve/sieve-result.c +++ b/pigeonhole/src/lib-sieve/sieve-result.c @@ -1274,6 +1274,7 @@ sieve_result_action_commit_or_rollback(struct sieve_result_execution *rexec, { struct sieve_result_action *rac = aexec->action; struct sieve_action *act = &rac->action; + const struct sieve_execute_env *exec_env = rexec->action_env.exec_env; /* Skip actions that are already finalized. */ if (aexec->state >= SIEVE_ACTION_EXECUTION_STATE_FINALIZED) @@ -1312,9 +1313,14 @@ sieve_result_action_commit_or_rollback(struct sieve_result_execution *rexec, /* This is bad; try to salvage as much as possible */ if (*commit_status == SIEVE_EXEC_OK) { *commit_status = cstatus; - if (!rexec->committed) { - /* We haven't executed anything yet; - continue as rollback */ + if (!rexec->committed || + exec_env->exec_status->store_failed) { + /* We haven't executed anything yet, + or storing mail locally failed; + continue as rollback. We generally + don't want to fail entirely, e.g. + a failed mail forward shouldn't + cause duplicate local deliveries. */ status = cstatus; } } |