From 38a0085b7844b5688e5ec8e106d2c0b9f4c57cec Mon Sep 17 00:00:00 2001 From: Karl Fleischmann Date: Mon, 6 Mar 2023 15:56:05 +0100 Subject: [PATCH] imap-login: Clarify variable naming of login ID param client_try_update_info() returns a boolean value that represents whether the given key has a login ID parameter handler, i.e. it is a login ID parameter. This commit changes the name to represent this more clearly. --- src/imap-login/imap-login-cmd-id.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/imap-login/imap-login-cmd-id.c b/src/imap-login/imap-login-cmd-id.c index a36f8533cb..c6ccc1c38d 100644 --- a/src/imap-login/imap-login-cmd-id.c +++ b/src/imap-login/imap-login-cmd-id.c @@ -134,15 +134,13 @@ static void cmd_id_handle_keyvalue(struct imap_client *client, struct imap_id_log_entry *log_entry, const char *key, const char *value) { - bool client_id_str; /* length of key + length of value (NIL for NULL) and two set of quotes and space */ size_t kvlen = strlen(key) + 2 + 1 + (value == NULL ? 3 : strlen(value)) + 2; + bool is_login_id_param = client_try_update_info(client, key, value); - client_id_str = !client_try_update_info(client, key, value); - - if (client->set->imap_id_retain && client_id_str && + if (client->set->imap_id_retain && !is_login_id_param && (client->common.client_id == NULL || str_len(client->common.client_id) + kvlen < LOGIN_MAX_CLIENT_ID_LEN)) { if (client->common.client_id == NULL) { -- 2.47.3