VirtualBox

Changeset 55042 in vbox for trunk/src


Ignore:
Timestamp:
Mar 31, 2015 3:35:20 PM (10 years ago)
Author:
vboxsync
Message:

3D: fix potential race in vboxhgcm.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/GuestHost/OpenGL/util/vboxhgcm.c

    r53726 r55042  
    24152415    {
    24162416        case CR_VBOXHGCM_MEMORY:
     2417            crDebug("crVBoxHGCMBufferFree: CR_VBOXHGCM_MEMORY: %p", hgcm_buffer);
    24172418            crFree( hgcm_buffer );
    24182419            break;
    24192420        case CR_VBOXHGCM_MEMORY_BIG:
     2421            crDebug("crVBoxHGCMBufferFree: CR_VBOXHGCM_MEMORY_BIG: %p", hgcm_buffer);
    24202422            crFree( hgcm_buffer );
    24212423            break;
     
    24502452    g_crvboxhgcm.initialized = 0;
    24512453
     2454    if (g_crvboxhgcm.bufpool)
     2455        crBufferPoolCallbackFree(g_crvboxhgcm.bufpool, crVBoxHGCMBufferFree);
     2456    g_crvboxhgcm.bufpool = NULL;
     2457
    24522458#ifdef CHROMIUM_THREADSAFE
    24532459    crUnlockMutex(&g_crvboxhgcm.mutex);
     
    24552461    crFreeMutex(&g_crvboxhgcm.recvmutex);
    24562462#endif
    2457 
    2458     if (g_crvboxhgcm.bufpool)
    2459         crBufferPoolCallbackFree(g_crvboxhgcm.bufpool, crVBoxHGCMBufferFree);
    2460     g_crvboxhgcm.bufpool = NULL;
    24612463
    24622464    crFree(g_crvboxhgcm.conns);
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