VirtualBox

Changeset 25880 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jan 18, 2010 11:26:35 AM (15 years ago)
Author:
vboxsync
Message:

Main: more locking order validation fixes

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/MachineImpl.cpp

    r25860 r25880  
    9797
    9898Machine::Data::Data()
    99     : mSnapshotsTreeLockHandle(LOCKCLASS_MACHINELIST)
     99    : mSnapshotsTreeLockHandle(LOCKCLASS_LISTOFSNAPSHOTS)
    100100{
    101101    mRegistered = FALSE;
     
    61336133    HRESULT rc = S_OK;
    61346134
    6135     /* Make sure the attached hard disks don't get unregistered until we
    6136      * associate them with tis machine (important for VMs loaded (opened) after
    6137      * VirtualBox startup) */
    6138     AutoReadLock vboxLock(mParent COMMA_LOCKVAL_SRC_POS);
    6139 
    61406135    for (settings::StorageControllersList::const_iterator it = data.llStorageControllers.begin();
    61416136         it != data.llStorageControllers.end();
  • trunk/src/VBox/Main/VirtualBoxImpl.cpp

    r25860 r25880  
    175175    Data()
    176176        : pMainConfigFile(NULL),
    177           ollMachines(LOCKCLASS_VIRTUALBOXLIST),
    178           ollGuestOSTypes(LOCKCLASS_VIRTUALBOXLIST),
    179           ollHardDisks(LOCKCLASS_VIRTUALBOXLIST),
    180           ollDVDImages(LOCKCLASS_VIRTUALBOXLIST),
    181           ollFloppyImages(LOCKCLASS_VIRTUALBOXLIST),
    182           ollSharedFolders(LOCKCLASS_VIRTUALBOXLIST),
    183           ollDHCPServers(LOCKCLASS_VIRTUALBOXLIST),
     177          ollMachines(LOCKCLASS_LISTOFMACHINES),
     178          ollGuestOSTypes(LOCKCLASS_LISTOFOTHEROBJECTS),
     179          ollHardDisks(LOCKCLASS_LISTOFMEDIA),
     180          ollDVDImages(LOCKCLASS_LISTOFMEDIA),
     181          ollFloppyImages(LOCKCLASS_LISTOFMEDIA),
     182          ollSharedFolders(LOCKCLASS_LISTOFOTHEROBJECTS),
     183          ollDHCPServers(LOCKCLASS_LISTOFOTHEROBJECTS),
    184184          mtxProgressOperations(LOCKCLASS_PROGRESSLIST),
    185185          updateReq(UPDATEREQARG),
     
    36583658    AssertComRCReturn(autoCaller.rc(), autoCaller.rc());
    36593659
    3660     ObjectsList<Medium> ollAll(LOCKCLASS_VIRTUALBOXLIST);
     3660    ObjectsList<Medium> ollAll(LOCKCLASS_LISTOFMEDIA);
    36613661    ollAll.appendOtherList(m->ollDVDImages);
    36623662    ollAll.appendOtherList(m->ollFloppyImages);
  • trunk/src/VBox/Main/glue/AutoLock.cpp

    r25842 r25880  
    7070    } aClasses[] =
    7171    {
    72         { LOCKCLASS_VIRTUALBOXOBJECT, "1-VIRTUALBOXOBJECT" },
    73         { LOCKCLASS_VIRTUALBOXLIST,   "2-VIRTUALBOXLIST" },
    74         { LOCKCLASS_USBPROXYSERVICE,  "3-USBPROXYSERVICE" },
    75         { LOCKCLASS_HOSTOBJECT,       "4-HOSTOBJECT" },
    76         { LOCKCLASS_MACHINEOBJECT,    "5-MACHINEOBJECT" },
    77         { LOCKCLASS_MACHINELIST,      "6-MACHINELIST" },
    78         { LOCKCLASS_SNAPSHOTOBJECT,   "7-SNAPSHOTOBJECT" },
    79         { LOCKCLASS_OTHEROBJECT,      "8-OTHEROBJECT" },
    80         { LOCKCLASS_USBLIST,          "9-USBLIST" },
    81         { LOCKCLASS_PROGRESSLIST,     "10-PROGRESSLIST" },
    82         { LOCKCLASS_OBJECTSTATE,      "11-OBJECTSTATE" }
     72        { LOCKCLASS_VIRTUALBOXOBJECT,   "1-VIRTUALBOXOBJECT" },
     73        { LOCKCLASS_USBPROXYSERVICE,    "2-USBPROXYSERVICE" },
     74        { LOCKCLASS_HOSTOBJECT,         "3-HOSTOBJECT" },
     75        { LOCKCLASS_LISTOFMACHINES,     "4-LISTOFMACHINES" },
     76        { LOCKCLASS_MACHINEOBJECT,      "5-MACHINEOBJECT" },
     77        { LOCKCLASS_LISTOFSNAPSHOTS,    "6-LISTOFSNAPSHOTS" },
     78        { LOCKCLASS_SNAPSHOTOBJECT,     "7-SNAPSHOTOBJECT" },
     79        { LOCKCLASS_LISTOFMEDIA,        "8-LISTOFMEDIA" },
     80        { LOCKCLASS_LISTOFOTHEROBJECTS, "9-LISTOFOTHEROBJECTS" },
     81        { LOCKCLASS_OTHEROBJECT,        "10-OTHEROBJECT" },
     82        { LOCKCLASS_USBLIST,            "11-USBLIST" },
     83        { LOCKCLASS_PROGRESSLIST,       "12-PROGRESSLIST" },
     84        { LOCKCLASS_OBJECTSTATE,        "13-OBJECTSTATE" }
    8385    };
    8486
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