DialogBoxParam (glob_hinst, (LPCTSTR)IDD_DEC, GetDesktopWindow (), decrypt_key_dlg_proc, (LPARAM)hd);
if (hd->flags & 0x01) DialogBoxParam (glob_hinst, (LPCSTR)IDD_DEC, GetDesktopWindow (), decrypt_key_dlg_proc, (LPARAM)hd); else DialogBoxParam (glob_hinst, (LPCTSTR)IDD_DEC_EXT, GetDesktopWindow (), decrypt_key_ext_dlg_proc, (LPARAM)hd);
passphrase_callback_box (void *opaque, const char *uid_hint, 			 const char *pass_info,			 int prev_was_bad, int fd){    struct decrypt_key_s * hd = (struct decrypt_key_s *)opaque;    DWORD nwritten = 0;    /* XXX: cancel for the decrypt dialog does not work */    if (hd->opts & OPT_FLAG_CANCEL) {	WriteFile ((HANDLE)fd, "\n", 1, &nwritten, NULL);	return -1;    }    if (prev_was_bad) {	free (hd->pass);	hd->pass = NULL;    }    if (hd && uid_hint && !hd->pass) {	const char * s = uid_hint;	size_t i=0;		while (s && *s != ' ')	    hd->keyid[i++] = *s++;	hd->keyid[i] = '\0'; s++;	if (hd->user_id) {	    free (hd->user_id);	    hd->user_id = NULL;	}	hd->user_id = (char *)xcalloc (1, strlen (s) + 2);	strcpy (hd->user_id, s);		if (hd->opts & OPT_FLAG_CANCEL) {	    WriteFile ((HANDLE)fd, "\n", 1, &nwritten, NULL);	    return -1;	}	hd->last_was_bad = prev_was_bad? 1: 0;	hd->use_as_cb = 1;	DialogBoxParam (glob_hinst, (LPCTSTR)IDD_DEC, GetDesktopWindow (),			decrypt_key_dlg_proc, (LPARAM)hd);    }    if (hd->pass) {	WriteFile ((HANDLE)fd, hd->pass, strlen (hd->pass), &nwritten, NULL);	WriteFile ((HANDLE)fd, "\n", 1, &nwritten, NULL);    }    else	WriteFile((HANDLE)fd, "\n", 1, &nwritten, NULL);    return 0;}