Changeset 38509 in vbox for trunk/include
- Timestamp:
- Aug 23, 2011 3:07:55 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/com/errorprint.h
r36536 r38509 36 36 // shared prototypes; these are defined in shared glue code and are 37 37 // compiled only once for all front-ends 38 void GluePrintErrorInfo(co m::ErrorInfo &info);38 void GluePrintErrorInfo(const com::ErrorInfo &info); 39 39 void GluePrintErrorContext(const char *pcszContext, const char *pcszSourceFile, uint32_t ulLine); 40 40 void GluePrintRCMessage(HRESULT rc); 41 void GlueHandleComError(ComPtr<IUnknown> iface, const char *pcszContext, HRESULT rc, const char *pcszSourceFile, uint32_t ulLine); 41 void GlueHandleComError(ComPtr<IUnknown> iface, 42 const char *pcszContext, 43 HRESULT rc, 44 const char *pcszSourceFile, 45 uint32_t ulLine); 46 void GlueHandleComErrorProgress(ComPtr<IProgress> progress, 47 const char *pcszContext, 48 HRESULT rc, 49 const char *pcszSourceFile, 50 uint32_t ulLine); 42 51 43 52 /** … … 153 162 } while (0) 154 163 164 165 /** 166 * Check the progress object for an error and if there is one print out the 167 * extended error information. 168 */ 169 #define CHECK_PROGRESS_ERROR(progress) \ 170 do { \ 171 LONG iRc; \ 172 rc = progress->COMGETTER(ResultCode)(&iRc); \ 173 if (FAILED(iRc)) \ 174 com::GlueHandleComErrorProgress(progress, __PRETTY_FUNCTION__, iRc, __FILE__, __LINE__); \ 175 } while (0) 176 177 /** 178 * Does the same as CHECK_PROGRESS_ERROR(), but executes the |return ret| statement on 179 * failure. 180 */ 181 #define CHECK_PROGRESS_ERROR_RET(progress, ret) \ 182 do { \ 183 LONG iRc; \ 184 rc = progress->COMGETTER(ResultCode)(&iRc); \ 185 if (FAILED(iRc)) \ 186 { \ 187 com::GlueHandleComErrorProgress(progress, __PRETTY_FUNCTION__, iRc, __FILE__, __LINE__); \ 188 return (ret); \ 189 } \ 190 } while (0) 191 155 192 /** 156 193 * Asserts the given expression is true. When the expression is false, prints
Note:
See TracChangeset
for help on using the changeset viewer.