Changeset 69330 in vbox
- Timestamp:
- Oct 26, 2017 9:34:35 AM (8 years ago)
- svn:sync-xref-src-repo-rev:
- 118654
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-server/MediumImpl.cpp
r69322 r69330 4769 4769 /* use the existing progress object... */ 4770 4770 pProgress = *aProgress; 4771 4771 } 4772 else 4773 { 4772 4774 /* ...but create a new one if it is null */ 4773 if (pProgress.isNull()) 4774 { 4775 pProgress.createObject(); 4776 rc = pProgress->init(m->pVirtualBox, 4777 static_cast<IMedium*>(this), 4778 BstrFmt(tr("Creating differencing medium storage unit '%s'"), 4779 aTarget->m->strLocationFull.c_str()).raw(), 4780 TRUE /* aCancelable */); 4781 if (FAILED(rc)) 4782 throw rc; 4783 } 4775 4776 pProgress.createObject(); 4777 rc = pProgress->init(m->pVirtualBox, 4778 static_cast<IMedium*>(this), 4779 BstrFmt(tr("Creating differencing medium storage unit '%s'"), 4780 aTarget->m->strLocationFull.c_str()).raw(), 4781 TRUE /* aCancelable */); 4782 if (FAILED(rc)) 4783 throw rc; 4784 4784 } 4785 4785 … … 5113 5113 /* use the existing progress object... */ 5114 5114 pProgress = *aProgress; 5115 5115 } 5116 else 5117 { 5116 5118 /* ...but create a new one if it is null */ 5117 5119 if (pProgress.isNull()) … … 5787 5789 /* use the existing progress object... */ 5788 5790 pProgress = *aProgress; 5789 5791 } 5792 else 5793 { 5790 5794 /* ...but create a new one if it is null */ 5791 if (pProgress.isNull()) 5792 { 5793 Utf8Str tgtName; 5794 { 5795 AutoReadLock alock(pTarget COMMA_LOCKVAL_SRC_POS); 5796 tgtName = pTarget->i_getName(); 5797 } 5798 5799 AutoReadLock alock(this COMMA_LOCKVAL_SRC_POS); 5800 5801 pProgress.createObject(); 5802 rc = pProgress->init(m->pVirtualBox, 5803 static_cast<IMedium*>(this), 5804 BstrFmt(tr("Merging medium '%s' to '%s'"), 5805 i_getName().c_str(), 5806 tgtName.c_str()).raw(), 5807 TRUE /* aCancelable */); 5808 if (FAILED(rc)) 5809 throw rc; 5810 } 5795 Utf8Str tgtName; 5796 { 5797 AutoReadLock alock(pTarget COMMA_LOCKVAL_SRC_POS); 5798 tgtName = pTarget->i_getName(); 5799 } 5800 5801 AutoReadLock alock(this COMMA_LOCKVAL_SRC_POS); 5802 5803 pProgress.createObject(); 5804 rc = pProgress->init(m->pVirtualBox, 5805 static_cast<IMedium*>(this), 5806 BstrFmt(tr("Merging medium '%s' to '%s'"), 5807 i_getName().c_str(), 5808 tgtName.c_str()).raw(), 5809 TRUE /* aCancelable */); 5810 if (FAILED(rc)) 5811 throw rc; 5811 5812 } 5812 5813 … … 5828 5829 { 5829 5830 rc = pTask->runNow(); 5830 5831 5831 delete pTask; 5832 5832 }
Note:
See TracChangeset
for help on using the changeset viewer.