]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
login-common: Include local_name in login_var_expand_table
authorAki Tuomi <aki.tuomi@dovecot.fi>
Thu, 20 Oct 2016 13:06:27 +0000 (16:06 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 20 Oct 2016 20:04:41 +0000 (23:04 +0300)
This way it can be used in login_log_format

src/login-common/client-common.c

index 1e5f1fba6d2c5057bdf6b52973a6b74c6e17f471..ba50482b5f7a480eaf9fcb7a500b9141a22f1ff5 100644 (file)
@@ -511,6 +511,7 @@ static struct var_expand_table login_var_expand_empty_tab[] = {
        { '\0', NULL, "auth_username" },
        { '\0', NULL, "auth_domain" },
        { '\0', NULL, "listener" },
+       { '\0', NULL, "local_name" },
        { '\0', NULL, NULL }
 };
 
@@ -585,6 +586,7 @@ get_var_expand_table(struct client *client)
                tab[24].value = tab[21].value;
        }
        tab[25].value = client->listener_name;
+       tab[26].value = str_sanitize(client->local_name, 256);
        return tab;
 }