]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
dict-client: When failing to resend commands after reconnect, their success is uncertain.
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Mon, 9 Jan 2017 20:39:09 +0000 (22:39 +0200)
committerGitLab <gitlab@git.dovecot.net>
Mon, 9 Jan 2017 23:48:42 +0000 (01:48 +0200)
It's possible that the writes before the disconnection did actually finish
successfully. If any of them were commits, we need to return
DICT_COMMIT_RET_WRITE_UNCERTAIN.

src/lib-dict/dict-client.c

index a283a35f6e3e03d1dec84d98a59123146c0bb103..b9cead612f42f62536caeaa87ce47c0dc583e76a 100644 (file)
@@ -346,7 +346,7 @@ client_dict_cmd_send(struct client_dict *dict, struct client_dict_cmd **_cmd,
        } else if (ret < 0) {
                i_assert(error != NULL);
                /* we didn't successfully send this command to dict */
-               dict_cmd_callback_error(cmd, error, FALSE);
+               dict_cmd_callback_error(cmd, error, cmd->reconnected);
                client_dict_cmd_unref(cmd);
                if (error_r != NULL)
                        *error_r = error;