Example #1
0
int get_userpass_input(prompts_t *p, unsigned char *in, int inlen)
{
    struct gui_data *inst = (struct gui_data *)p->frontend;
    int ret;
    ret = cmdline_get_passwd_input(p, in, inlen);
    if (ret == -1)
	ret = term_get_userpass_input(inst->term, p, in, inlen);
    return ret;
}
Example #2
0
int get_userpass_input_v2(void *frontend, prompts_t *p, unsigned char *in, int inlen)
{
    GuiTerminalWindow *f = static_cast<GuiTerminalWindow*>(frontend);
    int ret = -1;
    //ret = cmdline_get_passwd_input(p, in, inlen);
    if (ret == -1)
    ret = term_get_userpass_input(f->term, p, in, inlen);
    return ret;
}