VirtualBox

Changeset 39257 in vbox


Ignore:
Timestamp:
Nov 9, 2011 3:30:48 PM (13 years ago)
Author:
vboxsync
Message:

wddm/wine: missing CloseHandle & lock init/term

Location:
trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d/vboxext.c

    r38366 r39257  
    186186    FreeLibrary(pWorker->hSelf);
    187187
     188    CloseHandle(pWorker->hThread);
     189
    188190    return S_OK;
    189191}
  • trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d/wined3d_main.c

    r38363 r39257  
    150150}
    151151
     152#ifdef VBOX_WITH_WDDM
     153void WINAPI wined3d_mutex_init(void)
     154{
     155    InitializeCriticalSection(&wined3d_cs);
     156}
     157
     158void WINAPI wined3d_mutex_term(void)
     159{
     160    DeleteCriticalSection(&wined3d_cs);
     161}
     162#endif
     163
    152164static BOOL wined3d_dll_init(HINSTANCE hInstDLL)
    153165{
     
    161173    WNDCLASSA wc;
    162174
     175#ifdef VBOX_WITH_WDDM
     176    wined3d_mutex_init();
     177#endif
     178
    163179    wined3d_context_tls_idx = TlsAlloc();
    164180    if (wined3d_context_tls_idx == TLS_OUT_OF_INDEXES)
     
    166182        DWORD err = GetLastError();
    167183        ERR("Failed to allocate context TLS index, err %#x.\n", err);
     184#ifdef VBOX_WITH_WDDM
     185        wined3d_mutex_term();
     186#endif
    168187        return FALSE;
    169188    }
     
    192211            ERR("Failed to free context TLS index, err %#x.\n", err);
    193212        }
     213#ifdef VBOX_WITH_WDDM
     214        wined3d_mutex_term();
     215#endif
    194216        return FALSE;
    195217    }
     
    390412    UnregisterClassA(WINED3D_OPENGL_WINDOW_CLASS_NAME, hInstDLL);
    391413
     414#ifdef VBOX_WITH_WDDM
     415    wined3d_mutex_term();
     416#endif
     417
    392418    return TRUE;
    393419}
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