- Timestamp:
- Mar 7, 2011 10:17:33 AM (14 years ago)
- svn:sync-xref-src-repo-rev:
- 70383
- Location:
- trunk/src/VBox/Main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/include/MediumAttachmentImpl.h
r36058 r36181 91 91 void updateBandwidthGroup(const Utf8Str &aBandwidthGroup); 92 92 93 void updateParentMachine(Machine * const pMachine); 94 93 95 /** Get a unique and somewhat descriptive name for logging. */ 94 96 const char* getLogName(void) const { return mLogName.c_str(); } -
trunk/src/VBox/Main/src-server/MachineImpl.cpp
r36178 r36181 9591 9591 if (isSessionMachine()) 9592 9592 { 9593 /* 9594 * Update the parent machine to point to the new owner. 9595 * This is necessary because the stored parent will point to the 9596 * session machine otherwise and cause crashes or errors later 9597 * when the session machine gets invalid. 9598 * 9599 * @todo: Change the MediumAttachment class to behave like any other class 9600 * in this regard by creating peer MediumAttachment objects for 9601 * session machines and share the data with the peer machine. 9602 */ 9603 for (MediaData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin(); 9604 it != mMediaData->mAttachments.end(); 9605 ++it) 9606 { 9607 (*it)->updateParentMachine(mPeer); 9608 } 9609 9593 9610 /* attach new data to the primary machine and reshare it */ 9594 9611 mPeer->mMediaData.attach(mMediaData); -
trunk/src/VBox/Main/src-server/MediumAttachmentImpl.cpp
r36059 r36181 281 281 STDMETHODIMP MediumAttachment::COMGETTER(BandwidthGroup) (IBandwidthGroup **aBwGroup) 282 282 { 283 LogFlowThisFuncEnter(); 283 284 CheckComArgOutPointerValid(aBwGroup); 284 285 … … 300 301 } 301 302 303 LogFlowThisFuncLeave(); 302 304 return hrc; 303 305 } … … 426 428 } 427 429 430 void MediumAttachment::updateParentMachine(Machine * const pMachine) 431 { 432 LogFlowThisFunc(("ENTER - %s\n", getLogName())); 433 434 /* sanity */ 435 AutoCaller autoCaller(this); 436 AssertComRCReturnVoid (autoCaller.rc()); 437 438 AutoWriteLock alock(this COMMA_LOCKVAL_SRC_POS); 439 440 unconst(m->pMachine) = pMachine; 441 442 LogFlowThisFunc(("LEAVE - %s\n", getLogName())); 443 } 444
Note:
See TracChangeset
for help on using the changeset viewer.