git-svn-id: svn+ssh://svn.dolda2000.com/srv/svn/repos/src/doldaconnect@789
959494ce-11ee-0310-bf91-
de5d638817bd
}
if(data->converr)
{
- for(; i < nmsg; i++)
- {
- (*resp)[i].resp = sstrdup("");
- (*resp)[i].resp_retcode = PAM_SUCCESS;
- }
+ for(i--; i >= 0; i--)
+ free((*resp)[i].resp);
+ free(*resp);
+ *resp = NULL;
return(PAM_CONV_ERR);
}
+ (*resp)[i].resp_retcode = PAM_SUCCESS;
switch(msg[i]->msg_style)
{
case PAM_PROMPT_ECHO_OFF:
case PAM_PROMPT_ECHO_ON:
(*resp)[i].resp = sstrdup((char *)data->passdata);
memset((void *)data->passdata, 0, strlen((char *)data->passdata));
- (*resp)[i].resp_retcode = PAM_SUCCESS;
+ break;
+ default:
+ (*resp)[i].resp = NULL;
break;
}
}