VirtualBox

vbox的更動 62292 路徑 trunk/src/VBox/Main


忽略:
時間撮記:
2016-7-18 上午08:57:06 (8 年 以前)
作者:
vboxsync
訊息:

Main/Machine: Eliminate unneeded taking of the Host object lock in SessionMachine::uninit and additionally release the lock during IPC to be on the safe side (currently there is no problem).

檔案:
修改 1 筆資料

圖例:

未更動
新增
刪除
  • trunk/src/VBox/Main/src-server/MachineImpl.cpp

    r62192 r62292  
    1258912589    // we need to lock this object in uninit() because the lock is shared
    1259012590    // with mPeer (as well as data we modify below). mParent lock is needed
    12591     // by several calls to it, and USB needs host lock.
    12592     AutoMultiWriteLock3 multilock(mParent, mParent->i_host(), this COMMA_LOCKVAL_SRC_POS);
     12591    // by several calls to it.
     12592    AutoMultiWriteLock2 multilock(mParent, this COMMA_LOCKVAL_SRC_POS);
    1259312593
    1259412594#ifdef VBOX_WITH_RESOURCE_USAGE_API
     
    1264512645        while (it != mData->mSession.mRemoteControls.end())
    1264612646        {
     12647            ComPtr<IInternalSessionControl> pControl = *it;
     12648            mData->mSession.mRemoteControls.erase(it);
    1264712649            LogFlowThisFunc(("  Calling remoteControl->Uninitialize()...\n"));
    12648             HRESULT rc = (*it)->Uninitialize();
     12650            HRESULT rc = pControl->Uninitialize();
    1264912651            LogFlowThisFunc(("  remoteControl->Uninitialize() returned %08X\n", rc));
    1265012652            if (FAILED(rc))
    1265112653                Log1WarningThisFunc(("Forgot to close the remote session?\n"));
    12652             ++it;
     12654            multilock.acquire();
     12655            it = mData->mSession.mRemoteControls.begin();
    1265312656        }
    1265412657        mData->mSession.mRemoteControls.clear();
注意: 瀏覽 TracChangeset 來幫助您使用更動檢視器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette