diff --git a/client/common/client.c b/client/common/client.c index 9f40b226d..2bf72f42f 100644 --- a/client/common/client.c +++ b/client/common/client.c @@ -530,8 +530,8 @@ BOOL client_cli_authenticate_ex(freerdp* instance, char** username, char** passw return client_cli_authenticate_raw(instance, reason, username, password, domain); } -BOOL client_cli_choose_smartcard(SmartcardCertInfo** cert_list, DWORD count, DWORD* choice, - BOOL gateway) +BOOL client_cli_choose_smartcard(freerdp* instance, SmartcardCertInfo** cert_list, DWORD count, + DWORD* choice, BOOL gateway) { unsigned long answer; char* p = NULL; diff --git a/include/freerdp/client.h b/include/freerdp/client.h index bfe6c054a..ecbf2b6de 100644 --- a/include/freerdp/client.h +++ b/include/freerdp/client.h @@ -150,8 +150,8 @@ extern "C" FREERDP_API BOOL client_cli_authenticate_ex(freerdp* instance, char** username, char** password, char** domain, rdp_auth_reason reason); - FREERDP_API BOOL client_cli_choose_smartcard(SmartcardCertInfo** cert_list, DWORD count, - DWORD* choice, BOOL gateway); + FREERDP_API BOOL client_cli_choose_smartcard(freerdp* instance, SmartcardCertInfo** cert_list, + DWORD count, DWORD* choice, BOOL gateway); FREERDP_API int client_cli_logon_error_info(freerdp* instance, UINT32 data, UINT32 type); diff --git a/include/freerdp/freerdp.h b/include/freerdp/freerdp.h index 9dbd801b5..a75d3204e 100644 --- a/include/freerdp/freerdp.h +++ b/include/freerdp/freerdp.h @@ -136,8 +136,8 @@ extern "C" char** domain); typedef BOOL (*pAuthenticateEx)(freerdp* instance, char** username, char** password, char** domain, rdp_auth_reason reason); - typedef BOOL (*pChooseSmartcard)(SmartcardCertInfo** cert_list, DWORD count, DWORD* choice, - BOOL gateway); + typedef BOOL (*pChooseSmartcard)(freerdp* instance, SmartcardCertInfo** cert_list, DWORD count, + DWORD* choice, BOOL gateway); /** @brief Callback used if user interaction is required to accept * an unknown certificate. diff --git a/libfreerdp/core/smartcardlogon.c b/libfreerdp/core/smartcardlogon.c index 32aa8410e..fae94cc17 100644 --- a/libfreerdp/core/smartcardlogon.c +++ b/libfreerdp/core/smartcardlogon.c @@ -724,7 +724,7 @@ BOOL smartcard_getCert(const rdpContext* context, SmartcardCertInfo** cert, BOOL DWORD index; if (!instance->ChooseSmartcard || - !instance->ChooseSmartcard(cert_list, count, &index, gateway)) + !instance->ChooseSmartcard(context->instance, cert_list, count, &index, gateway)) { WLog_ERR(TAG, "more than one suitable smartcard certificate was found"); smartcardCertList_Free(cert_list, count);