summaryrefslogtreecommitdiffstats
path: root/crypto/openssh
diff options
context:
space:
mode:
authordes <des@FreeBSD.org>2003-09-24 18:26:29 +0000
committerdes <des@FreeBSD.org>2003-09-24 18:26:29 +0000
commit7ddad9d4af6ce6c209180f86ac66ccaed4925d87 (patch)
tree048b8e82c872787d450d81e169125a906faf8a45 /crypto/openssh
parent005a1d4afd94fdcab57e282de3965480f72b2688 (diff)
downloadFreeBSD-src-7ddad9d4af6ce6c209180f86ac66ccaed4925d87.zip
FreeBSD-src-7ddad9d4af6ce6c209180f86ac66ccaed4925d87.tar.gz
resp is a pointer to an array of structs, not an array of pointers to structs.
Diffstat (limited to 'crypto/openssh')
-rw-r--r--crypto/openssh/auth2-pam-freebsd.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/crypto/openssh/auth2-pam-freebsd.c b/crypto/openssh/auth2-pam-freebsd.c
index 234a67e..3653f65 100644
--- a/crypto/openssh/auth2-pam-freebsd.c
+++ b/crypto/openssh/auth2-pam-freebsd.c
@@ -134,8 +134,8 @@ pam_thread_conv(int n,
*resp = xmalloc(n * sizeof **resp);
buffer_init(&buffer);
for (i = 0; i < n; ++i) {
- resp[i]->resp_retcode = 0;
- resp[i]->resp = NULL;
+ (*resp)[i].resp_retcode = 0;
+ (*resp)[i].resp = NULL;
switch (msg[i]->msg_style) {
case PAM_PROMPT_ECHO_OFF:
buffer_put_cstring(&buffer, msg[i]->msg);
@@ -143,7 +143,7 @@ pam_thread_conv(int n,
ssh_msg_recv(ctxt->pam_csock, &buffer);
if (buffer_get_char(&buffer) != PAM_AUTHTOK)
goto fail;
- resp[i]->resp = buffer_get_string(&buffer, NULL);
+ (*resp)[i].resp = buffer_get_string(&buffer, NULL);
break;
case PAM_PROMPT_ECHO_ON:
buffer_put_cstring(&buffer, msg[i]->msg);
@@ -151,7 +151,7 @@ pam_thread_conv(int n,
ssh_msg_recv(ctxt->pam_csock, &buffer);
if (buffer_get_char(&buffer) != PAM_AUTHTOK)
goto fail;
- resp[i]->resp = buffer_get_string(&buffer, NULL);
+ (*resp)[i].resp = buffer_get_string(&buffer, NULL);
break;
case PAM_ERROR_MSG:
buffer_put_cstring(&buffer, msg[i]->msg);
@@ -550,20 +550,20 @@ pam_chauthtok_conv(int n,
for (i = 0; i < n; ++i) {
switch (msg[i]->msg_style) {
case PAM_PROMPT_ECHO_OFF:
- resp[i]->resp =
+ (*resp)[i].resp =
read_passphrase(msg[i]->msg, RP_ALLOW_STDIN);
- resp[i]->resp_retcode = PAM_SUCCESS;
+ (*resp)[i].resp_retcode = PAM_SUCCESS;
break;
case PAM_PROMPT_ECHO_ON:
fputs(msg[i]->msg, stderr);
fgets(input, sizeof input, stdin);
- resp[i]->resp = xstrdup(input);
- resp[i]->resp_retcode = PAM_SUCCESS;
+ (*resp)[i].resp = xstrdup(input);
+ (*resp)[i].resp_retcode = PAM_SUCCESS;
break;
case PAM_ERROR_MSG:
case PAM_TEXT_INFO:
fputs(msg[i]->msg, stderr);
- resp[i]->resp_retcode = PAM_SUCCESS;
+ (*resp)[i].resp_retcode = PAM_SUCCESS;
break;
default:
goto fail;
OpenPOWER on IntegriCloud