7zip/CPP/Common/ComTry.h

22 lines
491 B
C
Raw Normal View History

2021-12-27 01:00:00 +01:00
// ComTry.h
2023-06-21 02:00:00 +02:00
#ifndef ZIP7_INC_COM_TRY_H
#define ZIP7_INC_COM_TRY_H
2021-12-27 01:00:00 +01:00
#include "MyWindows.h"
// #include "Exception.h"
// #include "NewHandler.h"
#define COM_TRY_BEGIN try {
#define COM_TRY_END } catch(...) { return E_OUTOFMEMORY; }
/*
#define COM_TRY_END } \
catch(const CNewException &) { return E_OUTOFMEMORY; } \
catch(...) { return HRESULT_FROM_WIN32(ERROR_NOACCESS); } \
*/
// catch(const CSystemException &e) { return e.ErrorCode; }
// catch(...) { return E_FAIL; }
#endif