From b6c37221666737db4154408f919babc7233b5d22 Mon Sep 17 00:00:00 2001 From: dtucker Date: Sat, 24 Sep 2005 02:43:51 +0000 Subject: [PATCH] - (dtucker) [auth2.c] Move start_pam() calls out of if-else block to remove duplicate call. ok djm@ --- ChangeLog | 4 ++++ auth2.c | 12 ++++-------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index b3be8131..5372a18c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +20050924 + - (dtucker) [auth2.c] Move start_pam() calls out of if-else block to remove + duplicate call. ok djm@ + 20050922 - (dtucker) [configure.ac] Use -R linker flag for libedit too; patch from skeleten at shillest.net. diff --git a/auth2.c b/auth2.c index 613b0e2b..d255242e 100644 --- a/auth2.c +++ b/auth2.c @@ -156,21 +156,17 @@ input_userauth_request(int type, u_int32_t seq, void *ctxt) if (authctxt->pw && strcmp(service, "ssh-connection")==0) { authctxt->valid = 1; debug2("input_userauth_request: setting up authctxt for %s", user); -#ifdef USE_PAM - if (options.use_pam) - PRIVSEP(start_pam(authctxt)); -#endif } else { logit("input_userauth_request: invalid user %s", user); authctxt->pw = fakepw(); -#ifdef USE_PAM - if (options.use_pam) - PRIVSEP(start_pam(authctxt)); -#endif #ifdef SSH_AUDIT_EVENTS PRIVSEP(audit_event(SSH_INVALID_USER)); #endif } +#ifdef USE_PAM + if (options.use_pam) + PRIVSEP(start_pam(authctxt)); +#endif setproctitle("%s%s", authctxt->valid ? user : "unknown", use_privsep ? " [net]" : ""); authctxt->service = xstrdup(service); -- 2.45.2