[core,gateway] fixed missing/wrong return

This commit is contained in:
akallabeth 2023-02-14 08:08:56 +01:00 committed by akallabeth
parent 1f903f80a5
commit 34bc5e15f5
2 changed files with 4 additions and 3 deletions

View File

@ -180,13 +180,14 @@ BOOL rpc_ncacn_http_auth_init(rdpContext* context, RpcChannel* channel)
settings->GatewayPassword) < 0)
return FALSE;
credssp_auth_setup_client(auth, "HTTP", settings->GatewayHostname, &identity, NULL);
const BOOL res =
credssp_auth_setup_client(auth, "HTTP", settings->GatewayHostname, &identity, NULL);
sspi_FreeAuthIdentity(&identity);
credssp_auth_set_flags(auth, ISC_REQ_CONFIDENTIALITY);
return TRUE;
return res;
}
void rpc_ncacn_http_auth_uninit(RpcChannel* channel)

View File

@ -138,7 +138,7 @@ static int rpc_bind_setup(rdpRpc* rpc)
break;
case AUTH_CANCELLED:
freerdp_set_last_error_log(instance->context, FREERDP_ERROR_CONNECT_CANCELLED);
return FALSE;
return -1;
case AUTH_NO_CREDENTIALS:
freerdp_set_last_error_log(context, FREERDP_ERROR_CONNECT_NO_OR_MISSING_CREDENTIALS);
return 0;