]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
imap: imap-commands-util - Change client_find_namespace_full() parameter to command...
authorStephan Bosch <stephan.bosch@open-xchange.com>
Tue, 26 Aug 2025 23:32:46 +0000 (01:32 +0200)
committerStephan Bosch <stephan.bosch@open-xchange.com>
Mon, 26 Jan 2026 01:58:58 +0000 (02:58 +0100)
src/imap/cmd-select.c
src/imap/imap-commands-util.c
src/imap/imap-commands-util.h

index 418eb4415625778b51999424b8ab1d533428238a..3e9baae399152c7482b421443133446027d9fe0b 100644 (file)
@@ -388,7 +388,7 @@ bool cmd_select_full(struct client_command_context *cmd, bool readonly)
 
        ctx = p_new(cmd->pool, struct imap_select_context, 1);
        ctx->cmd = cmd;
-       ctx->ns = client_find_namespace_full(cmd->client, &mailbox, &client_error);
+       ctx->ns = client_find_namespace_full(cmd, &mailbox, &client_error);
        if (ctx->ns == NULL) {
                /* send * OK [CLOSED] before the tagged reply */
                close_selected_mailbox(client);
index acac8355684edd084a0cf0674e7a509ae07432cb..4647809cc4b37ca6391041e90d83632d19c57938 100644 (file)
 #include "imap-commands-util.h"
 
 struct mail_namespace *
-client_find_namespace_full(struct client *client,
+client_find_namespace_full(struct client_command_context *cmd,
                           const char **mailbox, const char **client_error_r)
 {
+       struct client *client = cmd->client;
        struct mail_namespace *namespaces = client->user->namespaces;
        struct mail_namespace *ns;
        string_t *utf8_name;
@@ -58,7 +59,7 @@ client_find_namespace(struct client_command_context *cmd, const char **mailbox)
        struct mail_namespace *ns;
        const char *client_error;
 
-       ns = client_find_namespace_full(cmd->client, mailbox, &client_error);
+       ns = client_find_namespace_full(cmd, mailbox, &client_error);
        if (ns == NULL)
                client_send_tagline(cmd, client_error);
        return ns;
index e297cc51c428da6bf63d16c86910ea1f5bfaf8e2..c8762a0ef99ee527e198f02e4402b4a282870350 100644 (file)
@@ -14,7 +14,7 @@ struct mailbox_keywords;
 struct mail_namespace *
 client_find_namespace(struct client_command_context *cmd, const char **mailbox);
 struct mail_namespace *
-client_find_namespace_full(struct client *client,
+client_find_namespace_full(struct client_command_context *cmd,
                           const char **mailbox, const char **client_error_r);
 
 /* Returns TRUE if mailbox is selected. If not, sends "No mailbox selected"