From 955d7f5dc107963f26f6e2c019855801ef6ff6b4 Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Thu, 21 Jul 2016 14:21:33 +0200 Subject: [PATCH] Missing credentials are correctly honoured now --- EAPMethods/src/Main_UI.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/EAPMethods/src/Main_UI.cpp b/EAPMethods/src/Main_UI.cpp index e5af446..ae5f0ab 100644 --- a/EAPMethods/src/Main_UI.cpp +++ b/EAPMethods/src/Main_UI.cpp @@ -361,10 +361,10 @@ DWORD WINAPI EapPeerInvokeIdentityUI( else { eap::config_providers cfg(g_peer); _EAPMETHOD_PEER_UI::credentials_type cred(g_peer); - if (!g_peer.unpack(cfg, pConnectionData, dwConnectionDataSize, ppEapError) || - !g_peer.unpack(cred, pUserData, dwUserDataSize, ppEapError) || - !g_peer.invoke_identity_ui(hwndParent, dwFlags, cfg, cred, ppwszIdentity, ppEapError) || - !g_peer.pack(cred, ppUserDataOut, pdwUserDataOutSize, ppEapError)) + if ( !g_peer.unpack(cfg, pConnectionData, dwConnectionDataSize, ppEapError) || + dwUserDataSize && !g_peer.unpack(cred, pUserData, dwUserDataSize, ppEapError) || + !g_peer.invoke_identity_ui(hwndParent, dwFlags, cfg, cred, ppwszIdentity, ppEapError) || + !g_peer.pack(cred, ppUserDataOut, pdwUserDataOutSize, ppEapError)) { if (*ppEapError) { g_peer.log_error(*ppEapError);