Changeset 94713 in vbox
- Timestamp:
- Apr 27, 2022 7:25:52 AM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 151092
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-server/UpdateAgentImpl.cpp
r94710 r94713 290 290 HRESULT UpdateAgent::init(VirtualBox *aVirtualBox) 291 291 { 292 // Enclose the state transition NotReady->InInit->Ready.293 AutoInitSpan autoInitSpan(this);294 AssertReturn(autoInitSpan.isOk(), E_FAIL);295 296 292 /* Weak reference to a VirtualBox object */ 297 293 unconst(m_VirtualBox) = aVirtualBox; … … 299 295 HRESULT hr = unconst(m_EventSource).createObject(); 300 296 if (SUCCEEDED(hr)) 301 {302 297 hr = m_EventSource->init(); 303 if (SUCCEEDED(hr))304 autoInitSpan.setSucceeded();305 }306 298 307 299 return hr; … … 751 743 ::FireUpdateAgentErrorEvent(m_EventSource, psz, vrc); 752 744 753 HRESULT const rc = setErrorVrc(VERR_COM_IPRT_ERROR /** @todo Translate HTTP errors to COM? */, p cszMsgFmt, va);745 HRESULT const rc = setErrorVrc(VERR_COM_IPRT_ERROR /** @todo Translate HTTP errors to COM? */, psz); 754 746 755 747 va_end(va); … … 790 782 AutoInitSpan autoInitSpan(this); 791 783 AssertReturn(autoInitSpan.isOk(), E_FAIL); 792 793 /* Weak reference to a VirtualBox object */794 unconst(m_VirtualBox) = aVirtualBox;795 784 796 785 /* Initialize the bare minimum to get things going. … … 802 791 m->strRepoUrl = "https://update.virtualbox.org"; 803 792 804 autoInitSpan.setSucceeded(); 805 return S_OK; 793 HRESULT hr = UpdateAgent::init(aVirtualBox); 794 if (SUCCEEDED(hr)) 795 autoInitSpan.setSucceeded(); 796 797 return hr; 806 798 } 807 799
Note:
See TracChangeset
for help on using the changeset viewer.