VirtualBox

Changeset 63070 in vbox for trunk/src/VBox/Additions/WINNT


Ignore:
Timestamp:
Aug 5, 2016 10:24:30 PM (8 years ago)
Author:
vboxsync
Message:

GA/NT: warnings

Location:
trunk/src/VBox/Additions/WINNT/VBoxCredProv
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/VBoxCredProv/VBoxCredProvCredential.cpp

    r62522 r63070  
    2424# define WIN32_NO_STATUS
    2525#endif
    26 #include <intsafe.h>
     26#include <iprt/win/intsafe.h>
    2727
    2828#include "VBoxCredentialProvider.h"
     
    754754 * @return  HRESULT
    755755 * @param   dwFieldID               Field to set value for.
    756  * @param   pcwzString              Actual value to set.
    757  */
    758 HRESULT
    759 VBoxCredProvCredential::SetStringValue(DWORD dwFieldID, PCWSTR pcwzString)
    760 {
     756 * @param   pwszValue               Actual value to set.
     757 */
     758HRESULT
     759VBoxCredProvCredential::SetStringValue(DWORD dwFieldID, PCWSTR pwszValue)
     760{
     761    RT_NOREF(dwFieldID, pwszValue);
    761762#ifdef DEBUG
    762763    VBoxCredProvVerbose(0, "VBoxCredProvCredential::SetStringValue: dwFieldID=%ld, pcwzString=%ls\n",
    763                         dwFieldID, pcwzString);
     764                        dwFieldID, pwszValue);
    764765#endif
    765766
     
    947948                if (SUCCEEDED(hr))
    948949                {
    949                     ULONG ulAuthPackage;
     950                    ULONG ulAuthPackage = 0;
     951/** @todo r=bird: The code flow here looks wrong.  The fact that ulAuthPackage
     952 *        wasn't initialized if LsaConnectUntrusted fails, but still used and
     953 *        we seemingly even succeed the operation as a whole.  Unfortunately,
     954 *        the code does not have any comments what-so-family-ever to
     955 *        enlighten us as to wtf (f == family) this Lsa stuff is doing and
     956 *        why it appear to be kind of optional...
     957 *
     958 *        I'm pretty sure this code if broken.  And if it is, it's because the
     959 *        stupid, stupid, code structure where you repeat state checks to avoid
     960 *        hugging the right margin.  The function is too long already, so the
     961 *        right way to deal with that is to split up the work into several
     962 *        functions with simplier control flow.
     963 */
     964#pragma message("TODO: Investigate code flow around ulAuthPackage!")
     965#ifdef DEBUG_andy
     966# error "fix this ASAP, it's been here since the r76490 rewrite"
     967#endif
    950968
    951969                    HANDLE hLsa;
     
    971989                        if (SUCCEEDED(hr))
    972990                        {
    973                             s = LsaLookupAuthenticationPackage(hLsa, &lsaszKerberosName,
    974                                                                &ulAuthPackage);
     991                            s = LsaLookupAuthenticationPackage(hLsa, &lsaszKerberosName, &ulAuthPackage);
    975992                            if (FAILED(HRESULT_FROM_NT(s)))
    976993                            {
     
    10231040                                     CREDENTIAL_PROVIDER_STATUS_ICON *pcpsiOptionalStatusIcon)
    10241041{
     1042    RT_NOREF(ntStatus, ntSubStatus, ppwszOptionalStatusText, pcpsiOptionalStatusIcon);
    10251043    VBoxCredProvVerbose(0, "VBoxCredProvCredential::ReportResult: ntStatus=%ld, ntSubStatus=%ld\n",
    10261044                        ntStatus, ntSubStatus);
  • trunk/src/VBox/Additions/WINNT/VBoxCredProv/VBoxCredProvCredential.h

    r62811 r63070  
    7474    IFACEMETHODIMP GetSubmitButtonValue(DWORD dwFieldID, DWORD *pdwAdjacentTo);
    7575
    76     IFACEMETHODIMP SetStringValue(DWORD dwFieldID, PCWSTR pcwzString);
     76    IFACEMETHODIMP SetStringValue(DWORD dwFieldID, PCWSTR pwszValue);
    7777    IFACEMETHODIMP SetCheckboxValue(DWORD dwFieldID, BOOL fChecked);
    7878    IFACEMETHODIMP SetComboBoxSelectedValue(DWORD dwFieldID, DWORD dwSelectedItem);
  • trunk/src/VBox/Additions/WINNT/VBoxCredProv/VBoxCredProvProvider.cpp

    r62522 r63070  
    2222#include <new> /* For bad_alloc. */
    2323
     24#include <iprt/win/windows.h>
    2425#include <credentialprovider.h>
    2526
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette