VirtualBox

Changeset 105885 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Aug 28, 2024 10:55:08 AM (3 months ago)
Author:
vboxsync
Message:

Main: Better fix for GraphicsAdapter::isFeatureEnabled() if a feature is not supported; now it always returns S_OK but reports back FALSE. bugref:10749

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-server/GraphicsAdapterImpl.cpp

    r105879 r105885  
    305305    switch (aFeature)
    306306    {
    307 /// @todo r=bird: This '#ifndef causes 2+ error messages popping up on arm when
    308 /// starting a VM. I don't think VBOX_E_NOT_SUPPORTED is an appropiate
    309 /// answer to a simple question whether a feature is supported or not. Returning
    310 /// FALSE would be a lot more helpful in my opinion.
    311 //#ifndef VBOX_WITH_VIRT_ARMV8 /* On macOS (ARM) we don't support any 2D/3D acceleration for now. */
     307#ifndef VBOX_WITH_VIRT_ARMV8 /* On macOS (ARM) we don't support any 2D/3D acceleration for now. */
    312308        case GraphicsFeature_Acceleration2DVideo:
    313309            pfSetting = &mData->fAccelerate2DVideo;
     
    318314            pfSetting = &mData->fAccelerate3D;
    319315            break;
    320 //#endif
     316#endif
    321317        default:
    322318            break;
    323319    }
    324320
    325     if (!pfSetting)
    326         return VBOX_E_NOT_SUPPORTED;
    327 
    328     *aEnabled = *pfSetting;
     321    *aEnabled = pfSetting ? *pfSetting : FALSE;
    329322
    330323    return S_OK;
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