Added Redirect callback

This commit is contained in:
Armin Novak 2021-12-15 10:58:43 +01:00 committed by akallabeth
parent b545094664
commit d248b635a5
2 changed files with 21 additions and 11 deletions

View File

@ -112,6 +112,7 @@ extern "C"
typedef BOOL (*pPreConnect)(freerdp* instance);
typedef BOOL (*pPostConnect)(freerdp* instance);
typedef BOOL (*pRedirect)(freerdp* instance);
typedef void (*pPostDisconnect)(freerdp* instance);
typedef BOOL (*pAuthenticate)(freerdp* instance, char** username, char** password,
char** domain);
@ -446,7 +447,13 @@ fingerprint. DEPRECATED: Use VerifyChangedCertificateEx */
Callback for gateway consent messages.
It is used to present consent messages to the user. */
UINT64 paddingD[64 - 58]; /* 58 */
ALIGN64 pRedirect
Redirect; /**< (offset 59)
Callback for redirect operations.
Can be set after rdp_client_disconnect_and_clear and applying redirection
settings but before rdp_client_connect() to have it executed after the
actual connection has succeeded. Must be set to NULL if not needed. */
UINT64 paddingD[64 - 59]; /* 59 */
ALIGN64 pSendChannelData
SendChannelData; /* (offset 64)

View File

@ -606,6 +606,9 @@ BOOL rdp_client_redirect(rdpRdp* rdp)
return FALSE;
}
if (!IFCALLRESULT(TRUE, rdp->instance->Redirect, rdp->instance))
return FALSE;
status = rdp_client_connect(rdp);
if (status)