From: Timo Sirainen Date: Fri, 6 Jul 2018 10:23:58 +0000 (+0300) Subject: login-proxy: Fix potential crash when kicking user with alt username X-Git-Tag: 2.3.9~1593 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=455abfe05f85f1fb65cfa2c72caad5a9c9d2efd7;p=thirdparty%2Fdovecot%2Fcore.git login-proxy: Fix potential crash when kicking user with alt username If a new alt username field was returned after other users already were being proxied, trying to kick with the new alt username field will crash. --- diff --git a/src/login-common/login-proxy.c b/src/login-common/login-proxy.c index 645943258a..4390196ab3 100644 --- a/src/login-common/login-proxy.c +++ b/src/login-common/login-proxy.c @@ -773,6 +773,8 @@ want_kick_alt_username(struct client *client, const char *const *args, if (client->alt_usernames[i] == NULL) return FALSE; } + if (client->alt_usernames[i] == NULL) + return FALSE; return str_array_find(args, client->alt_usernames[i]); }