VirtualBox

Changeset 95118 in vbox for trunk/src/VBox/Main


Ignore:
Timestamp:
May 25, 2022 8:57:49 PM (3 years ago)
Author:
vboxsync
Message:

Main/VirtualBoxImpl: Don't use DECLCALLBACKPTR for a C++ callback which certainly may throw std::bad_alloc if not worse (noexcept/c++17).

Location:
trunk/src/VBox/Main
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/include/VirtualBoxImpl.h

    r94737 r95118  
    148148
    149149#ifdef RT_OS_WINDOWS
    150     typedef DECLCALLBACKPTR(HRESULT, SVCHelperClientFunc,(SVCHlpClient *aClient, Progress *aProgress, void *aUser, int *aVrc));
     150    typedef HRESULT (*PFN_SVC_HELPER_CLIENT_T)(SVCHlpClient *aClient, Progress *aProgress, void *aUser, int *aVrc);
    151151    HRESULT i_startSVCHelperClient(bool aPrivileged,
    152                                    SVCHelperClientFunc aFunc,
     152                                   PFN_SVC_HELPER_CLIENT_T aFunc,
    153153                                   void *aUser, Progress *aProgress);
    154154#endif
  • trunk/src/VBox/Main/src-server/VirtualBoxImpl.cpp

    r94863 r95118  
    30863086              Progress* aProgress,
    30873087              bool aPrivileged,
    3088               VirtualBox::SVCHelperClientFunc aFunc,
     3088              VirtualBox::PFN_SVC_HELPER_CLIENT_T aFunc,
    30893089              void *aUser)
    30903090    {
     
    31093109    ComObjPtr<Progress> progress;
    31103110    bool privileged;
    3111     VirtualBox::SVCHelperClientFunc func;
     3111    VirtualBox::PFN_SVC_HELPER_CLIENT_T func;
    31123112    void *user;
    31133113    ThreadVoidData *threadVoidData;
     
    31713171 */
    31723172HRESULT VirtualBox::i_startSVCHelperClient(bool aPrivileged,
    3173                                            SVCHelperClientFunc aFunc,
     3173                                           PFN_SVC_HELPER_CLIENT_T aFunc,
    31743174                                           void *aUser, Progress *aProgress)
    31753175{
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