Mercurial > dovecot > core-2.2
changeset 21056:46532ea9d84c
auth: Make static analyzer happier.
Don't complain about uninitialized static_password being sent to
passdb_handle_credentials(). It could only happen for failures, and
passdb_handle_credentials() wouldn't have used the password then.
author | Timo Sirainen <timo.sirainen@dovecot.fi> |
---|---|
date | Wed, 02 Nov 2016 23:00:50 +0200 |
parents | eb645ebb4c3e |
children | d373fde16da7 |
files | src/auth/passdb-static.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/auth/passdb-static.c Wed Nov 02 21:59:12 2016 +0200 +++ b/src/auth/passdb-static.c Wed Nov 02 23:00:50 2016 +0200 @@ -17,6 +17,9 @@ struct static_passdb_module *module = (struct static_passdb_module *)request->passdb->passdb; + *password_r = NULL; + *scheme_r = NULL; + auth_request_log_debug(request, AUTH_SUBSYS_DB, "lookup"); passdb_template_export(module->tmpl, request); @@ -28,8 +31,6 @@ } else { auth_request_log_info(request, AUTH_SUBSYS_DB, "No password returned (and no nopassword)"); - *password_r = NULL; - *scheme_r = NULL; return PASSDB_RESULT_PASSWORD_MISMATCH; }