VirtualBox

Ignore:
Timestamp:
Jun 20, 2018 11:27:14 AM (7 years ago)
Author:
vboxsync
Message:

WDDM: display driver: handle the case when VBOXWDDMDISP_DEVICE::DefaultContext is not initialized

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiDisp.cpp

    r69500 r72621  
    163163    PVBOXUHGSMI_PRIVATE_D3D pHg = VBOXUHGSMID3D_GET(pHgsmi);
    164164    PVBOXWDDMDISP_DEVICE pDevice = pHg->pDevice;
     165
     166    AssertReturn(pDevice->DefaultContext.ContextInfo.hContext, VERR_GENERAL_FAILURE);
     167
    165168    UINT cbDmaCmd = pDevice->DefaultContext.ContextInfo.CommandBufferSize;
    166169    int rc = vboxUhgsmiBaseDxDmaFill(aBuffers, cBuffers,
     
    207210    PVBOXUHGSMI_PRIVATE_D3D pPrivate = VBOXUHGSMID3D_GET(pHgsmi);
    208211    PVBOXWDDMDISP_DEVICE pDevice = pPrivate->pDevice;
     212
     213    AssertReturn(pDevice->DefaultContext.ContextInfo.hContext, VERR_GENERAL_FAILURE);
     214
    209215    D3DDDICB_ESCAPE DdiEscape = {0};
    210216    DdiEscape.hContext = pDevice->DefaultContext.ContextInfo.hContext;
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