Changeset 44970 in vbox for trunk/src/VBox/Main/src-client
- Timestamp:
- Mar 11, 2013 9:59:05 AM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 84190
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-client/VirtualBoxClientImpl.cpp
r44529 r44970 5 5 6 6 /* 7 * Copyright (C) 2010-201 1Oracle Corporation7 * Copyright (C) 2010-2013 Oracle Corporation 8 8 * 9 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 #include "VBoxEvents.h" 22 22 #include "Logging.h" 23 #include "VBox/com/ErrorInfo.h" 23 24 24 25 #include <iprt/asm.h> … … 199 200 200 201 return mData.m_pEventSource.isNull() ? E_FAIL : S_OK; 202 } 203 204 /** 205 * Checks a Machine object for any pending errors. 206 * 207 * @returns COM status code 208 * @param aMachine Machine object to check. 209 */ 210 STDMETHODIMP VirtualBoxClient::CheckMachineError(IMachine *aMachine) 211 { 212 HRESULT rc; 213 CheckComArgNotNull(aMachine); 214 215 BOOL fAccessible = FALSE; 216 rc = aMachine->COMGETTER(Accessible)(&fAccessible); 217 if (FAILED(rc)) 218 return setError(rc, tr("Could not check the accessibility status of the VM")); 219 else if (!fAccessible) 220 { 221 ComPtr<IVirtualBoxErrorInfo> pAccessError; 222 rc = aMachine->COMGETTER(AccessError)(pAccessError.asOutParam()); 223 if (FAILED(rc)) 224 return setError(rc, tr("Could not get the access error message of the VM")); 225 else 226 { 227 ErrorInfo info(pAccessError); 228 ErrorInfoKeeper eik(info); 229 return info.getResultCode(); 230 } 231 } 232 return S_OK; 201 233 } 202 234
Note:
See TracChangeset
for help on using the changeset viewer.